[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: [xml] Correction for Tutorial Code
- From: John Fleck <jfleck inkstain net>
- To: niraj tolia <ntolia hotmail com>
- Cc: xml gnome org
- Subject: Re: [xml] Correction for Tutorial Code
- Date: Wed, 30 Oct 2002 10:55:03 -0700
On Wed, Oct 30, 2002 at 05:51:08PM +0000, niraj tolia wrote:
>
> So I was looking at the Tutorial Code
> (http://www.xmlsoft.org/tutorial/index.html) and saw that it leaks memory. I
> was wondering if this could be fixed as it is entirely non-clear to first
> time users of libxml as to what the semantics of functions like
> xmlNodeListGetString() are. The sample code (eg
> http://www.xmlsoft.org/tutorial/apb.html) makes it look like the function
> simply returns a pointer to a string.
>
> However you need to go through the API to find out that the function
> actually allocates memory that the caller needs to free. I would appreciate
> it if an xmlFree() was put in there. The same applies for calls such as
> xmlGetProp().
>
Thanks. I will try to fix this.
Could you do me a favor and file a bug report at bugzilla.gnome.org (the
product is libxml2 and the component is docs) so this doesn't get lost?
Cheers,
John
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]