WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
173110
[Cocoa] JSWrapperMap leaks for all JSContexts
https://bugs.webkit.org/show_bug.cgi?id=173110
Summary
[Cocoa] JSWrapperMap leaks for all JSContexts
Joseph Pecoraro
Reported
2017-06-08 14:17:26 PDT
Summary: JSWrapperMap leaks for all JSContexts Test: /* * shell> xcrun clang -framework Foundation -framework JavaScriptCore js-leak.m */ #import <Foundation/Foundation.h> #import <JavaScriptCore/JavaScriptCore.h> int main() { @autoreleasepool { [[[JSContext alloc] init] autorelease]; } [[NSRunLoop mainRunLoop] run]; return 0; } Steps to Reproduce: 1. $ xcrun clang -framework Foundation -framework JavaScriptCore js-leak.m 2. $ MallocStackLogging=1 DYLD_FRAMEWORK_PATH=$build/Release ./a.out 3. $ leaks `pidof a.out` => Leaks Leak: Leak: 0x7f9b18100ce0 size=32 zone: DefaultMallocZone_0x10ecb8000 JSWrapperMap ObjC JavaScriptCore 0x0e58d0f5 0x001d8001 0x181008d0 0x00007f9b ..X............. 0x186125c0 0x00007f9b 0x18100ec0 0x00007f9b .%a............. Call stack: [thread 0x7fffb956e3c0]: | start | main | -[JSContext initWithVirtualMachine:] JSContext.mm:79 | -[JSContext ensureWrapperMap] JSContext.mm:57 | _objc_rootAlloc | class_createInstance | calloc
Attachments
[PATCH] Proposed Fix
(1.37 KB, patch)
2017-06-08 14:23 PDT
,
Joseph Pecoraro
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Joseph Pecoraro
Comment 1
2017-06-08 14:17:40 PDT
<
rdar://problem/32602198
>
Joseph Pecoraro
Comment 2
2017-06-08 14:23:42 PDT
Created
attachment 312342
[details]
[PATCH] Proposed Fix
Geoffrey Garen
Comment 3
2017-06-08 14:48:03 PDT
Comment on
attachment 312342
[details]
[PATCH] Proposed Fix r=me
WebKit Commit Bot
Comment 4
2017-06-08 15:24:14 PDT
Comment on
attachment 312342
[details]
[PATCH] Proposed Fix Clearing flags on attachment: 312342 Committed
r217952
: <
http://trac.webkit.org/changeset/217952
>
WebKit Commit Bot
Comment 5
2017-06-08 15:24:16 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug