Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Sanity check header tag values. Like, doh.
There's a check for total number of tags, and their types and all but absolutely no check for the actual tag numbers. So we end up accepting negative tags which should not exist. The tag type should really be uint32_t but that's another can of worms, lets have something easily backportable for now. This is enough to fix issues #133, #135, #136, #138 and #139 on the level of detecting header structural inconsistency. Backported from commit 3a07ba3: headerVerifyInfo() is so different in git master we can't use the same exact thing here. Instead we do things in two steps, headerVerifyInfo() catches totally garbage values and duplicate regions are caught in regionSwab().
- Loading branch information