Browse files

Fixed super selector leak for ALL cases

  • Loading branch information...
1 parent 2541dfa commit 71c1c7fa0d5071878837d39110fc116ba03269af @parmanoir committed Aug 3, 2011
View
6 JSCocoa/JSCocoaController.m
@@ -4768,12 +4768,10 @@ static JSValueRef jsCocoaObject_callAsFunction(JSContextRef ctx, JSObjectRef fun
{
JSStringRef resultStringJS = JSValueToStringCopy(ctx, arguments[1], NULL);
superSelector = (NSString*)JSStringCopyCFString(kCFAllocatorDefault, resultStringJS);
+ [superSelector autorelease];
JSStringRelease(resultStringJS);
- if (callingSwizzled) {
- NSString* previousSelector = superSelector;
+ if (callingSwizzled)
superSelector = [NSString stringWithFormat:@"%@%@", OriginalMethodPrefix, superSelector];
- [previousSelector release];
- }
}
// Swizzled handling : we're just changing the selector
View
1,503 ....xcodeproj/project.xcworkspace/xcuserdata/mini.xcuserdatad/UserInterfaceState.xcuserstate
747 additions, 756 deletions not shown because the diff is too large. Please use a local Git client to view these changes.

0 comments on commit 71c1c7f

Please sign in to comment.