Page 1 of 1

loadConfig memleak

Posted: 16 Sep 2009, 22:26
by roocell
found this is leaking some memory
need to release NSURL* url;

added the release after it was used. this seems to stop the leak.

Code: Select all

doc = [[CXMLDocument alloc] initWithContentsOfURL:url options:0 error:&error];
[url release];

Posted: 22 Sep 2009, 15:48
by cemuzunlar
Thanks. We'll include this fix to the next release.

CLANG found this too for me.....and a few other things

Posted: 06 Jan 2010, 19:21
by cBroadbo
While you are fixing this for the next release, I would suggest running CLANG (Build/Build & Analyze) in the latest version of xCode. It found this leak and a handful of variables possibly being used without being initialized.

Re: CLANG found this too for me.....and a few other things

Posted: 08 Feb 2010, 13:12
by skrekkur
cBroadbo wrote:While you are fixing this for the next release, I would suggest running CLANG (Build/Build & Analyze) in the latest version of xCode. It found this leak and a handful of variables possibly being used without being initialized.


I must agree with this. Clang exposes some potentially dangerous code paths.
It would also be nice to have the API completely warning free.
Or at least leave comments where warnings are generated if there is some valid explanation for them. Currently at least NSObjectAddition generates two warnings (one for each function).

Posted: 11 Mar 2010, 16:56
by Lapo
New release here:
viewtopic.php?t=6994