Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix LineBucket::addGeometry() empty coordinates. #2959

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

clinthidinger
Copy link

This fix avoids using a negative number to index the coordinates inside the "len" lambda in LineBucket::addGeometry(). It does an early return similar to the one on line ~90 for invalid geometry.

Copy link
Collaborator

@cgalvan cgalvan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add a unit test for this?

@clinthidinger
Copy link
Author

Can we add a unit test for this?

Are there docs for how to run the unit tests? When I run the mbgl-test-runner project, it says:

[==========] Running 0 tests from 0 test suites.
[==========] 0 tests from 0 test suites ran. (1 ms total)
[ PASSED ] 0 tests.

I tried filtering for Buckets.LineBucket, but that didn't help.

@louwers
Copy link
Collaborator

louwers commented Oct 24, 2024

That should work. What platform are you on? Could be that we don't have it set up properly for Windows.

@clinthidinger
Copy link
Author

That should work. What platform are you on? Could be that we don't have it set up properly for Windows.

I'm on Windows 11 with GLFW as the platform.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants