⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 282221 in webkit


Ignore:
Timestamp:
Sep 9, 2021, 10:02:27 AM (5 years ago)
Author:
Patrick Angle
Message:

run-webkit-archive crashes with dyld error
​https://bugs.webkit.org/show_bug.cgi?id=228060

Reviewed by Alex Christensen.

Source/JavaScriptCore:

Add a compatibility symbol for the old WTF::Optional version of BackendDispatcher::reportProtocolError in
versions of Safari shipping with macOS Big Sur and earlier. This has the side effect of not surfacing protocol
errors and instead silently discarding them when crossing this API boundary. Newer versions of macOS ship using
the newer symbol and are therefor not affected and will continue to surface protocol errors to the frontend.

  • runtime/SymbolStubsForSafariCompatibility.mm:

(Inspector::BackendDispatcher::reportProtocolError):

Source/WTF:

Bump the maximum macOS version that HAVE_SAFARI_FOR_WEBKIT_DEVELOPMENT_REQUIRING_EXTRA_SYMBOLS will be enabled
to provide compatibility with changes made in macOS 12.

  • wtf/PlatformHave.h:
Location:
trunk/Source
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r282212 r282221  
     12021-09-09  Patrick Angle  <pangle@apple.com>
     2
     3        run-webkit-archive crashes with dyld error
     4        https://bugs.webkit.org/show_bug.cgi?id=228060
     5
     6        Reviewed by Alex Christensen.
     7
     8        Add a compatibility symbol for the old `WTF::Optional` version of `BackendDispatcher::reportProtocolError` in
     9        versions of Safari shipping with macOS Big Sur and earlier. This has the side effect of not surfacing protocol
     10        errors and instead silently discarding them when crossing this API boundary. Newer versions of macOS ship using
     11        the newer symbol and are therefor not affected and will continue to surface protocol errors to the frontend.
     12
     13        * runtime/SymbolStubsForSafariCompatibility.mm:
     14        (Inspector::BackendDispatcher::reportProtocolError):
     15
    1162021-09-09  Justin Michaud  <justin_michaud@apple.com>
    217
  • trunk/Source/JavaScriptCore/runtime/SymbolStubsForSafariCompatibility.mm

    r273515 r282221  
    3838template<typename, typename> class RefPtr { };
    3939template<typename> struct DumbPtrTraits { };
     40template<typename> class Optional { };
    4041
    4142namespace JSONImpl {
    … …  
    5859
    5960class BackendDispatcher {
     61    enum CommonErrorCode { NotUsed };
     62
    6063    JS_EXPORT_PRIVATE void sendResponse(long, WTF::RefPtr<WTF::JSONImpl::Object, WTF::DumbPtrTraits<WTF::JSONImpl::Object>>&&, bool);
     64    JS_EXPORT_PRIVATE void reportProtocolError(WTF::Optional<long>, CommonErrorCode, const WTF::String&);
    6165};
    6266void BackendDispatcher::sendResponse(long, WTF::RefPtr<WTF::JSONImpl::Object, WTF::DumbPtrTraits<WTF::JSONImpl::Object>>&&, bool) { }
     67void BackendDispatcher::reportProtocolError(WTF::Optional<long>, CommonErrorCode, const WTF::String&) { }
    6368
    6469} // namespace Inspector
  • trunk/Source/WTF/ChangeLog

    r282137 r282221  
     12021-09-09  Patrick Angle  <pangle@apple.com>
     2
     3        run-webkit-archive crashes with dyld error
     4        https://bugs.webkit.org/show_bug.cgi?id=228060
     5
     6        Reviewed by Alex Christensen.
     7
     8        Bump the maximum macOS version that `HAVE_SAFARI_FOR_WEBKIT_DEVELOPMENT_REQUIRING_EXTRA_SYMBOLS` will be enabled
     9        to provide compatibility with changes made in macOS 12.
     10
     11        * wtf/PlatformHave.h:
     12
    1132021-09-08  Jean-Yves Avenard  <jya@apple.com>
    214
  • trunk/Source/WTF/wtf/PlatformHave.h

    r282061 r282221  
    458458#endif
    459459
    460 #if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED < 110300
     460#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED < 120000
    461461#define HAVE_SAFARI_FOR_WEBKIT_DEVELOPMENT_REQUIRING_EXTRA_SYMBOLS 1
    462462#endif
Note: See TracChangeset for help on using the changeset viewer.