Hi Paul,

You said 'an object you don't manage' -- If I alloc/init an instance of NSTimer I am responsible for this object, in my opinion. That's why I tried to do everything properly. You see I am actually really just trying to prevent memory leaks and I see lots of leaks in sample code I am downloading somewhere. That's the reason I am so careful. Let's just close the topic here, I thank everyone for the explanations, I appreciate all of them!

Best regards,
Tobias Jordan.

On Mar 13, 2010, at 9:53 PM, Paul Sanders wrote:

I don't understand all the confusion on this issue.  The NSTimer
documentation makes the life-cycle of this object very clear.
Until it goes away, it is probably retained by the runloop.

As Joar says, you often can't make any concrete predictions
about when an object you don't manage yourself might be released
for the last time, but if you put a breakpoint on [NSTimer
dealloc] you will be able to see it when it happens.

Paul Sanders.




_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to