Changeset 171984 in webkit


Ignore:
Timestamp:
Aug 3, 2014 12:21:49 PM (10 years ago)
Author:
mitz@apple.com
Message:

<rdar://problem/17782529> REGRESSION: OS marketing version in iOS Simulator user-agent string is the host OS’s
https://bugs.webkit.org/show_bug.cgi?id=135549

Reviewed by Mark Rowe.

  • platform/cocoa/SystemVersion.mm:

(WebCore::createSystemMarketingVersion): On the iOS Simulator, locate the system Library
directory relative to the Simulator root.

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r171973 r171984  
     12014-08-03  Dan Bernstein  <mitz@apple.com>
     2
     3        <rdar://problem/17782529> REGRESSION: OS marketing version in iOS Simulator user-agent string is the host OS’s
     4        https://bugs.webkit.org/show_bug.cgi?id=135549
     5
     6        Reviewed by Mark Rowe.
     7
     8        * platform/cocoa/SystemVersion.mm:
     9        (WebCore::createSystemMarketingVersion): On the iOS Simulator, locate the system Library
     10        directory relative to the Simulator root.
     11
    1122014-08-02  Jeremy Jones  <jeremyj@apple.com>
    213
  • trunk/Source/WebCore/platform/cocoa/SystemVersion.mm

    r170730 r171984  
    3434    // Can't use -[NSProcessInfo operatingSystemVersionString] because it has too much stuff we don't want.
    3535    NSString *systemLibraryPath = [NSSearchPathForDirectoriesInDomains(NSLibraryDirectory, NSSystemDomainMask, YES) objectAtIndex:0];
     36#if PLATFORM(IOS_SIMULATOR)
     37    if (char *simulatorRoot = getenv("SIMULATOR_ROOT"))
     38        systemLibraryPath = [NSString stringWithFormat:@"%s/%@", simulatorRoot, systemLibraryPath];
     39#endif
    3640    NSString *systemVersionPlistPath = [systemLibraryPath stringByAppendingPathComponent:@"CoreServices/SystemVersion.plist"];
    3741    NSDictionary *systemVersionInfo = [NSDictionary dictionaryWithContentsOfFile:systemVersionPlistPath];
Note: See TracChangeset for help on using the changeset viewer.