Note that there are some explanatory texts on larger screens.

plurals
  1. POexc_bad_access dismissModalViewControllerAnimated
    primarykey
    data
    text
    <p>I'm new in iPhone SDK dev, and I'm not an englishman, so my apologies for my level.</p> <p>Here is my problem: I've a tabBarcontroller, with 3 item, each has a navBarcontroller</p> <pre><code>[self.loginViewController release]; [self setLoginViewController:[[LoginViewController alloc] init]]; [[self loginViewController] setDelegate:self]; [[self loginViewController] isLoggued]; self.tabBarController = [[UITabBarController alloc] init]; _FirstViewController = [[[FirstViewController alloc] init] autorelease]; _FirstViewController.title = @"title 1"; UINavigationController* navController1 = [[[UINavigationController alloc] initWithRootViewController:_FirstViewController] autorelease]; _SecondViewController = [[[SecondViewController alloc] init] autorelease]; _SecondViewController.title = @"title 2"; UINavigationController* navController2 = [[[UINavigationController alloc] initWithRootViewController:_SecondViewController] autorelease]; _ThirdViewController = [[[_ThirdViewController alloc] init] autorelease]; _ThirdViewController.title = @"title 3"; UINavigationController* navController3 = [[[UINavigationController alloc] initWithRootViewController:_ThirdViewController] autorelease]; self.tabBarController.viewControllers = [NSArray arrayWithObjects:navController1, navController2, navController3, nil]; [self.window addSubview:self.tabBarController.view]; // adds the tab bar's view property to the window [self.window makeKeyAndVisible]; [self.tabBarController release]; if ([self respondsToSelector:@selector(loginViewControllerLogout:)]) { [self performSelector:@selector(loginViewControllerLogout:) withObject:[self loginViewController]]; } return YES; </code></pre> <p>Here this is the selector</p> <pre><code>-(void)loginViewControllerLogout:(LoginViewController *)loginViewController { if (![self.loginViewController logguedIn]) [self.tabBarController presentModalViewController:self.loginViewController animated:YES]; } </code></pre> <p>And When I'm loggued, I call:</p> <pre><code>-(void)loginViewControllerDidFinish:(LoginViewController *)loginViewController { [self.loginViewController dismissModalViewControllerAnimated:YES]; } </code></pre> <p>These piece of code work when the App is launching for the first time. LoginViewController displayed > login successfull > LoginViewcontroller dismiss > FirstViewController displaying. But if I go to the thirdViewController, click on logout: selector LoginViewControllerLogout called > LoginViewController displayed > Login successfull > Crash in the dismissModal.</p> <p>There is no error stack, just the exc_bad_access error. There is more than 1 retain for loginViewController.</p> <p>Thanks in advance</p> <p>EDIT: all functions are in the AppDelegate</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload