<div dir="ltr">i have been using valgrind so far and it helped me resolve a lot of seg faults. Thanks for the advice strk. :)<div><br></div><div style>Thanks,</div><div style>Vishal</div></div><div class="gmail_extra"><br>
<br><div class="gmail_quote">On 17 July 2013 18:27, 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="im">On Wed, Jul 17, 2013 at 06:24:44PM +0530, vishal tiwari wrote:<br>
> Hi Peter,<br>
><br>
> It was giving me the error that i specified before, because the object was<br>
> been deleted when it was returned to the different function (i think this<br>
> was the reason). So i made a copy of it using clone(), and returned its<br>
> pointer, and it worked. :)<br>
<br>
</div>Yep, those kind of errors are common when you hand around pointers to<br>
memory that's released before use. Valgrind is an excellent tool to<br>
find these cases (hint: use it against your testcases, those memory<br>
errors do not _always_ get to the surface).<br>
<br>
--strk;<br>
<div class="HOEnZb"><div class="h5"><br>
><br>
> Thanks,<br>
> Vishal<br>
><br>
><br>
> On 17 July 2013 15:15, Peter Körner <<a href="mailto:osm-lists@mazdermind.de">osm-lists@mazdermind.de</a>> wrote:<br>
><br>
> > Hi vishal tiwari,<br>
> ><br>
> > Am 17.07.2013 09:58, schrieb vishal tiwari:<br>
> > > sorry to bother you, i just fixed it. :)<br>
> > would you mind telling us what your issue was, so we (partly also not<br>
> > that familar witc C++) can take part of your solution?<br>
> ><br>
> > Peter<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>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr">Vishal Tiwari<div>Undergraduate</div><div>Computer Science and Engineering</div><div>Lab for Spatial Informatics</div><div>IIIT-Hyderabad</div>
</div>
</div>