Skip to content

Conversation

@Manas-Dikshit
Copy link

This PR fixes a compile-time error in BinaryParser.java caused by improper wrapping of a non-IOException inside UncheckedIOException.

Details
Removed: throw new UncheckedIOException(new FileFormatException(e));
Added: throw new FileFormatException(e);
FileFormatException already extends RuntimeException, making it suitable to throw directly.
Also added a small safety check in getStringById() to prevent potential ArrayIndexOutOfBoundsException for malformed PBF data.

Impact
Fixes compilation errors in the Java build (mvn package or ant).
Improves runtime safety and error clarity when parsing malformed OSM PBF files.

@joto
Copy link
Collaborator

joto commented Dec 3, 2025

Please don't mix unrelated changes in a single PR. In this case the code changes with unrelated whitespace or wording changes. This makes is very hard to review the change set.

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.

2 participants