[geos-devel] Question about GEOSPolygonize_full_r
sean.gillies at gmail.com
Fri Jul 19 08:49:58 PDT 2013
Thanks a bunch, strk! I got it sorted out with your reminder:
On Fri, Jul 19, 2013 at 1:34 AM, Sandro Santilli <strk at keybit.net> wrote:
> On Thu, Jul 18, 2013 at 09:47:35PM -0600, Sean Gillies wrote:
> > Hi all,
> > Shapely users have been asking me about access to GEOSPolygonize_full_r
> > I'm looking into it today. One thing I don't understand about the
> > (not being much of a C++ programmer anymore) is why the cuts, dangles,
> > invalid rings are only retrieved if the pointers passed in for them are
> > NULL?
> > http://trac.osgeo.org/geos/browser/tags/3.3.8/capi/geos_ts_c.cpp#L3077
> > Wouldn't it be better if the pointers *were* NULL since they are supposed
> > to point to memory allocated by this function instead of bringing in data
> > from the caller?
> The pointer value (*cuts) can be null, the code doesn't even check for
> But you pass a pointer to the pointer, so that the code can change the
> pointer value.
> geos-devel mailing list
> geos-devel at lists.osgeo.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the geos-devel