开发者

UITableViewCell - super dealloc EXC_BAD_ACCESS

What could cause a [super dealloc]; to crash?

So I have this in my UITableViewCell

- (void)dealloc
{
    // this is ok
    [others release];

    // this crash
    [super dealloc];
}

Basically I have a UITabViewController. When I navigate to another tab, and come back to this tab that contains the UITableViewCell, it will crash at [super dealloc];

This is how the cell is getting called.

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
    static NSString *CellIdentifier = @"DynamicSizedCell";

DynamicSizedCell *cell = (DynamicSizedCell *)[tableView dequeueReusableCellWithIdentifier:CellIdentifier];  
if (cell == n开发者_开发知识库il) {
    cell = [[[DynamicSizedCell alloc] init] autorelease];
}

[cell setSelectionStyle:UITableViewCellSelectionStyleNone];
return cell;

}

Thanks,

Tee

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜