<div dir="ltr">Thanks a bunch, strk! I got it sorted out with your reminder: <a href="https://github.com/Toblerity/Shapely/issues/57">https://github.com/Toblerity/Shapely/issues/57</a>.<br></div><div class="gmail_extra"><br>
<br><div class="gmail_quote">On Fri, Jul 19, 2013 at 1:34 AM, Sandro Santilli <span dir="ltr"><<a href="mailto:strk@keybit.net" target="_blank">strk@keybit.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5">On Thu, Jul 18, 2013 at 09:47:35PM -0600, Sean Gillies wrote:<br>
> Hi all,<br>
><br>
> Shapely users have been asking me about access to GEOSPolygonize_full_r and<br>
> I'm looking into it today. One thing I don't understand about the function<br>
> (not being much of a C++ programmer anymore) is why the cuts, dangles, and<br>
> invalid rings are only retrieved if the pointers passed in for them are not<br>
> NULL?<br>
><br>
> <a href="http://trac.osgeo.org/geos/browser/tags/3.3.8/capi/geos_ts_c.cpp#L3077" target="_blank">http://trac.osgeo.org/geos/browser/tags/3.3.8/capi/geos_ts_c.cpp#L3077</a><br>
><br>
> Wouldn't it be better if the pointers *were* NULL since they are supposed<br>
> to point to memory allocated by this function instead of bringing in data<br>
> from the caller?<br>
<br>
</div></div>The pointer value (*cuts) can be null, the code doesn't even check for that.<br>
But you pass a pointer to the pointer, so that the code can change the<br>
pointer value.<br>
<br>
--strk;<br>
_______________________________________________<br>
geos-devel mailing list<br>
<a href="mailto:geos-devel@lists.osgeo.org">geos-devel@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/geos-devel" target="_blank">http://lists.osgeo.org/mailman/listinfo/geos-devel</a><br>
</blockquote></div><br><br clear="all"><br>-- <br>Sean Gillies
</div>