Im facing memory leaks in many cases when I try to parse JSON. Thought its telling SBJsonParser , I know that wont be a cause.
- (id)JSONValue {
SBJsonParser *jsonParser = [SBJsonParser new];
id repr = [jsonParser objectWithString:self]; // 100.0 % Memory Leak
if (!repr)
NSLog(@"-JSONValue failed. Error is: %@", jsonParser.error);
[jsonParser release];
return repr;
}
and also memory leak happening at
"id result=[JSON valueForKeyPath:@"result"]; "
// 100.0% memory leak
id repr = [jsonParser objectWithString:self]; // 80.0% Memory Leak
What I need to do to fix this > :( Thanks.