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 memory exception in LWGEOM_GEOS_makeValidCollection #21

Closed

Conversation

@ahuarte47
Copy link

commented Apr 3, 2014

No description provided.

@strk

This comment has been minimized.

Copy link
Member

commented Jun 26, 2014

What's the point of this patch ? The "vgeoms" variable is lwfree-d right after passing it to GEOSGeom_createCollection, less code for the same result

@strk strk closed this Jun 26, 2014

@ahuarte47

This comment has been minimized.

Copy link
Author

commented Jun 26, 2014

Te code is calling GEOSGeom_destroy(vgeoms[i]); after free vgeoms

@strk strk reopened this Jun 26, 2014

@strk

This comment has been minimized.

Copy link
Member

commented Jun 26, 2014

Ah! Good catch.
Do you also have an actual dataset triggering that ?

@ahuarte47

This comment has been minimized.

Copy link
Author

commented Jun 26, 2014

No, I am sorry, I saw it studing the code for QGIS issues

@strk

This comment has been minimized.

Copy link
Member

commented Jun 26, 2014

@strk strk closed this Jun 26, 2014

@ahuarte47

This comment has been minimized.

Copy link
Author

commented Jun 26, 2014

Thanks to you Sandro!

@ahuarte47 ahuarte47 deleted the ahuarte47:Issue_makeValidCollection branch Jun 26, 2014

strk pushed a commit that referenced this pull request Jun 26, 2014

Sandro Santilli
Fix potential memory fault in ST_MakeValid
The fault would be triggered by passing a non-empty collection
to ST_MakeValid where any "made-valid" component would result
being non accepted by the final geometry collection constructor.

I'm not sure an input exists right now to trigger that case,
but worth fixing anyway.

Bug found by Alvaro Huarte:
#21

git-svn-id: http://svn.osgeo.org/postgis/branches/2.1@12667 b70326c6-7e19-0410-871a-916f4a2858ee

strk pushed a commit that referenced this pull request Jun 26, 2014

Sandro Santilli
Fix potential memory fault in ST_MakeValid
The fault would be triggered by passing a non-empty collection
to ST_MakeValid where any "made-valid" component would result
being non accepted by the final geometry collection constructor.

I'm not sure an input exists right now to trigger that case,
but worth fixing anyway.

Bug found by Alvaro Huarte:
#21

git-svn-id: http://svn.osgeo.org/postgis/trunk@12666 b70326c6-7e19-0410-871a-916f4a2858ee

Algunenano added a commit to Algunenano/postgis that referenced this pull request Jul 18, 2018

Merge pull request postgis#21 from Algunenano/24_carto_update
Merge community branch (svn-2.4 2018-07-18)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.