Ignore:
Timestamp:
Dec 17, 2008, 10:10:51 AM (16 years ago)
Author:
[email protected]
Message:

Reviewed by Darin Adler.

Don't use unique context group in JSGlobalContextCreate() on Tiger or Leopard, take two.

  • API/JSContextRef.cpp: The previous patch that claimed to do this was making Tiger and Leopard always use unique context group instead.
File:
1 edited

Legend:

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

    r39330 r39360  
    6161JSGlobalContextRef JSGlobalContextCreate(JSClassRef globalObjectClass)
    6262{
    63 #if PLATFORM(DARWIN) && !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD)
     63#if PLATFORM(DARWIN)
     64    // When running on Tiger or Leopard, or if the application was linked before JSGlobalContextCreate was changed
     65    // to use a unique JSGlobalData, we use a shared one for compatibility.
     66#if !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD)
    6467    if (NSVersionOfLinkTimeLibrary("JavaScriptCore") <= webkitFirstVersionWithConcurrentGlobalContexts) {
     68#else
     69    {
     70#endif
    6571        JSLock lock(true);
    6672        return JSGlobalContextCreateInGroup(toRef(&JSGlobalData::sharedInstance()), globalObjectClass);
    6773    }
    68 #endif
     74#endif // PLATFORM(DARWIN)
     75
    6976    return JSGlobalContextCreateInGroup(0, globalObjectClass);
    7077}
Note: See TracChangeset for help on using the changeset viewer.