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

Guarding against empty polygons which would otherwise crash. #4

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

Conversation

DoctorLoki
Copy link

When passing coords into the geos.NewPolygon calls, there was a lack of checking whether the coordsArray was empty before dereferencing that array, potentially causing crashes, e.g. while trying to unmarshal JSON. Adding these guards avoids the crashes and results in detectable errors instead.

@DoctorLoki
Copy link
Author

@jyutzler Maybe you could take a look at this simple change request?

@jyutzler
Copy link
Contributor

jyutzler commented Sep 8, 2019

Sorry, I am no longer affiliated with this project. @matthewhanson @smesdaghi can you take a look?

@DoctorLoki
Copy link
Author

Thanks Jeff! Any word from @matthewhanson or @smesdaghi yet?

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