Je charge ma vue de xib. Et quand essayer de libérer, il se bloque avec le message:L'application se bloque sur Dealloc
Project Designer (72849,0xa08c0540) malloc: * erreur pour objet 0x4b06000: pointeur étant libéré n'a pas été alloué * mis un point d'arrêt dans malloc_error_break de débogage actuel langue: auto; actuellement c objectif
Voici mon implémentation:
@interface ACLine : UIView {
NSMutableArray *chevrons;
}
- (void)addChevron:(ACChevron *)aChevron;
- (void)addChevron:(ACChevron *)aChevron atIndex:(NSInteger)anIndex;
- (void)removeAllChevrons;
- (void)removeChevron:(ACChevron *)aChevron;
- (void)removeChevronAtIndex:(NSInteger)anIndex;
- (void)update;
@property (nonatomic, retain) NSMutableArray *chevrons;
@end
@implementation ACLine
@synthesize chevrons;
- (void)awakeFromNib {
chevrons = [[NSMutableArray alloc] init];
}
- (void)dealloc {
self.chevrons = nil;
[super dealloc]; it crashes here
}
S'il vous plaît aider à résoudre le problème. Merci.
Oui, le même problème – Sergio