I'm getting crazy with Build-Analyze and leaks, so I'll apreciate any help with these code:
1- First code:
-(void)viewDidLoad {
self.navigationItem.titleView = [[[UIImageView alloc] autorelease] initWithImage:[UIImage imageNamed:@"myImage.png"]];
[self.navigationController.navigationBar setTintColor:[UIColor colorWithRed:1 green:0.529 blue:0 alpha:1.0]];
[super viewDidLoad];
}
In this case the analyzer returns "Object sent - too many times (2)", and I don't know why!!!
2- In this other code the analyzer says "Potential leak of an object allocated on line 88" (line 88 is the first one):
- (void)annotationViewClick {
InfoCategoriaViewController *nextController = [[InfoCategoriaViewController alloc] initWithNibName:@"infoCategoriaView" bundle:nil];
[self.navigationController pushViewController:nextController animated:YES];
[nextController verCategoria:par_nombre arg_distancia:par_distancia arg_direccion:par_direccion];
}
In this code I've tried to release the pointer "nextController", but the app crashes if I do that :-(
Thank you.