Changeset 37868 in webkit for trunk/JavaScriptCore/API


Ignore:
Timestamp:
Oct 24, 2008, 3:16:09 PM (17 years ago)
Author:
[email protected]
Message:

Suggested and rubber-stamped by Geoff Garen.

Fix a crash when opening Font Picker.

The change also hopefully fixes this bug, which I could never reproduce:
https://bugs.webkit.org/show_bug.cgi?id=20241
<rdar://problem/6290576> Safari crashes at JSValueUnprotect() when fontpicker view close

  • API/JSContextRef.cpp: (JSContextGetGlobalObject): Use lexical global object instead of dynamic one.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/API/JSContextRef.cpp

    r37845 r37868  
    121121
    122122    // It is necessary to call toThisObject to get the wrapper object when used with WebCore.
    123     return toRef(exec->dynamicGlobalObject()->toThisObject(exec));
     123    return toRef(exec->lexicalGlobalObject()->toThisObject(exec));
    124124}
    125125
Note: See TracChangeset for help on using the changeset viewer.