Skip to content

Conversation

@bdon
Copy link
Contributor

@bdon bdon commented Jan 30, 2025

  • the leafStart was only assigned in flushEntries, which never happens if there is only a root directory.
  • resulted in erroneous leafDirectoryOffset and tileDataLength in the pmtiles header.

Detect with pmtiles verify:

pmtiles verify main.pmtiles
2025/01/30 15:11:57 main.go:223: Failed to verify archive, Leaf directories offset=0 must not be 0
exit status 1

Fixes #794

* the leafStart was only assigned in flushEntries, which never happens if there is only a root directory.
* resulted in erroneous leafDirectoryOffset and tileDataLength in the pmtiles header.
@systemed systemed merged commit 0d01bc5 into systemed:master Jan 30, 2025
7 checks passed
@systemed
Copy link
Owner

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

root-directory-only pmtiles archives have incorrect header offsets

2 participants