0
我正在審查一些源代碼,並注意到下面的這個方法。它在分配後不會釋放message
。節目後不應該有[message release];
?UIAlertView並顯示它後釋放對象
- (void)service:(TestService*)service didFailWithError:(NSObject *)error
{
UIAlertView *message = [[UIAlertView alloc] initWithTitle:@"Service Error"
message:errorMsg
delegate:nil
cancelButtonTitle:@"OK"
otherButtonTitles:nil];
[message show];
}