potential leak? - analyzer
analyze state leak p开发者_开发技巧roblem, why?
+ (DebugOutput *) sharedDebug
{
@synchronized(self)
{
if (sharedDebugInstance == nil)
{
[[self alloc] init];
}
}
return sharedDebugInstance;
}
Well sharedDebugInstance is not assigned, you probably wanted to do that:
sharedDebugInstance = [[self alloc] init];
精彩评论