Skip to content

Commit

Permalink
Fix failing assert due to off-by-one error
Browse files Browse the repository at this point in the history
  • Loading branch information
ThijsdeJong-TomTom authored and joto committed Aug 27, 2023
1 parent da01259 commit d50c346
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/extract/extract_polygon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ ExtractPolygon::ExtractPolygon(const osmium::io::File& output_file, const std::s

m_bands.resize(num_bands + 1);

m_dy = (y_max() - y_min()) / num_bands;
m_dy = (y_max() - y_min() + num_bands - 1) / num_bands;

// put segments into the bands they overlap
for (const auto& segment : segments) {
Expand Down

0 comments on commit d50c346

Please sign in to comment.