WebKit Bugzilla
Attachment 343703 Details for
Bug 187089
: [GTK][WPE] Use LazyNeverDestroyed<XErrorTrapper> to remove static initializers
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-187089-20180627180739.patch (text/plain), 2.27 KB, created by
Yusuke Suzuki
on 2018-06-27 02:07:40 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Yusuke Suzuki
Created:
2018-06-27 02:07:40 PDT
Size:
2.27 KB
patch
obsolete
>Subversion Revision: 233249 >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index ee3b41443ec370b58d24d48bb013cb85baa986a4..d361f14845aa0fb69f9a4f3feada4ec69770c74b 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,17 @@ >+2018-06-27 Yusuke Suzuki <utatane.tea@gmail.com> >+ >+ [GTK][WPE] Use LazyNeverDestroyed<XErrorTrapper> to remove static initializers >+ https://bugs.webkit.org/show_bug.cgi?id=187089 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Use LazyNeverDestroyed<XErrorTrapper> instead of global std::unique_ptr<XErrorTrapper>. >+ Since this variable's exit time destructor is not important in this code, using >+ LazyNeverDestroyed<XErrorTrapper> is fine. This removes the last static initializer >+ of libwebkit2gtk.so. >+ >+ * PluginProcess/unix/PluginProcessMainUnix.cpp: >+ > 2018-06-26 Wenson Hsieh <wenson_hsieh@apple.com> > > [iPad apps on macOS] Unable to interact with video elements that have started playing >diff --git a/Source/WebKit/PluginProcess/unix/PluginProcessMainUnix.cpp b/Source/WebKit/PluginProcess/unix/PluginProcessMainUnix.cpp >index 91f82b65980711b1255ba2b9b1d29fddeacc25a6..2bd2ed59ae6a2e24b0748b03cebc3563c667183e 100644 >--- a/Source/WebKit/PluginProcess/unix/PluginProcessMainUnix.cpp >+++ b/Source/WebKit/PluginProcess/unix/PluginProcessMainUnix.cpp >@@ -44,12 +44,13 @@ > #if PLATFORM(X11) > #include <WebCore/PlatformDisplayX11.h> > #include <WebCore/XErrorTrapper.h> >+#include <wtf/NeverDestroyed.h> > #endif > > namespace WebKit { > > #if PLATFORM(X11) >-static std::unique_ptr<WebCore::XErrorTrapper> xErrorTrapper; >+static LazyNeverDestroyed<WebCore::XErrorTrapper> xErrorTrapper; > #endif > > class PluginProcessMain final: public ChildProcessMainBase { >@@ -82,7 +83,7 @@ class PluginProcessMain final: public ChildProcessMainBase { > #if PLATFORM(X11) > if (WebCore::PlatformDisplay::sharedDisplay().type() == WebCore::PlatformDisplay::Type::X11) { > auto* display = downcast<WebCore::PlatformDisplayX11>(WebCore::PlatformDisplay::sharedDisplay()).native(); >- xErrorTrapper = std::make_unique<WebCore::XErrorTrapper>(display, WebCore::XErrorTrapper::Policy::Warn); >+ xErrorTrapper.construct(display, WebCore::XErrorTrapper::Policy::Warn); > } > #endif >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 187089
:
343703
|
343705