[Gpsbabel-code] gpx tag tree free changes
Brought to you by:
robertl
From: Robert L. <rob...@us...> - 2003-04-17 03:59:00
|
This is in the intersection of two pieces of code I didn't write. The GPX tree stuff and the "free what you take" stuff came from others. This passes a test suite run when built with electric fence, so I don't think this stuff is used after I vaporize it, but I'd like someone that really understands it (Ron?) to rubber stamp an OK on this before I commit it. Thanx, RJL Index: gpx.c =================================================================== RCS file: /cvsroot/gpsbabel/gpsbabel/gpx.c,v retrieving revision 1.41 diff -p -u -r1.41 gpx.c --- gpx.c 16 Apr 2003 14:24:29 -0000 1.41 +++ gpx.c 17 Apr 2003 03:53:46 -0000 @@ -881,6 +881,12 @@ void free_gpx_extras( xml_tag *tag ) if (tag->parentcdata) { xfree(tag->parentcdata); } + if (tag->tagname) { + xfree(tag->tagname); + } + if (tag->attributes) { + xfree(tag->attributes); + } next = tag->sibling; xfree(tag); tag = next; |