I need some help with releasing a controller in xcode ..im not using ARC ..take a look at this simple code from my main delegate controller:
LoginViewController *login = [[LoginViewController alloc] init];
[window addSubview:login.view];
[window makeKeyAndVisible];
[login release]; // code runs if i comment out this line
If i comment out the last line the program runs. The program crashes on the last line ...i put in a zombie and here is the result: 2012-08-17 09:43:02.193 dialer[238:707] * -[LoginViewController performSelector:withObject:withObject:]: message sent to deallocated instance 0x186360
how can i trace this and why is this even happing since im allocating and releasing right away. Does it have something to do with retain , etc