Re: dealloc never called
Re: dealloc never called
- Subject: Re: dealloc never called
- From: Philipp Ringli <email@hidden>
- Date: Mon, 7 Feb 2005 02:38:09 +0100
Won't work either. :(
also this...
- (void)applicationWillTerminate:(NSNotification *)aNotification
{
NSLog(@"terminating!\n");
}
... never makes it to the log.
Maybe I am missing something basic, that I should have done in IB?
On 07.02.2005, at 02:24, Agent M wrote:
Let me guess, you are looking for the "dealloc!" that never shows up.
If this is the case, you have become a victim of I/O buffering. The
application quits before the output (stderr) buffer is flushed so you
don't see the message. If you add a newline output to the string like
so:
NSLog(@"dealloc!\n");
then you should see it.
If not, something else is going on that we can't see from your current
code. One possibility is that you retained this object too many times.
On Feb 6, 2005, at 7:59 PM, Philipp Ringli wrote:
I have this code in my Controller.m and it never executes upon
quitting the app:
----------------------------------------
- (void)dealloc
{
NSLog (@"dealloc!");
[self saveData]; // just to be sure that the
// latest data is saved to disk
[prefs synchronize];
[prefs release];
[classPathRecords release];
//[recordsFile release];
// recordsFile = nil;
classPathRecords = nil;
prefs = nil;
[super dealloc]; // pass the ball to Controller's
// superclass so it can do its own deallocation
}
-----------------------------------------
Probably again something basic, I am missing?
Cheers,
Phil
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
email@hidden
This email sent to email@hidden
¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬
AgentM
email@hidden
¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden