gnustep-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Static analyser results for -base (277 potential bugs)


From: David Chisnall
Subject: Re: Static analyser results for -base (277 potential bugs)
Date: Sat, 11 Sep 2010 15:12:57 +0100

On 11 Sep 2010, at 15:00, Fred Kiefer wrote:

> Am 11.09.2010 12:28, schrieb David Chisnall:
>> On 10 Sep 2010, at 20:18, Fred Kiefer wrote:
>> 
>>> Thank you for doing this, would you mind to run it over gui as well? Not
>>> that I currently have time to fix the hundreds of bugs this would find...
>> 
>> 
>> And here are the results for the cairo back end - only 16 bugs, at least one 
>> of which is a false positive:
> 
> Fixed the ones that I found to real and worthwhile. I am not sure why
> the static analysis complains about [GSGState copyWithZone:] doesn't it
> know about NSCopyObject or is the method call to [deepen] confusing it?

It's the call to -deepen.  It doesn't know that this returns self, so it looks 
to the analyser as if you are allocating an object then returning an 
autoreleased object that this object returns and leaking the original object.  
This is clearly wrong, so it complains.  In fact, you are creating an object 
and returning it, which is sensible.

David


reply via email to

[Prev in Thread] Current Thread [Next in Thread]