Title: [282517] releases/WebKitGTK/webkit-2.32/Source/WebKit
- Revision
- 282517
- Author
- [email protected]
- Date
- 2021-09-16 02:30:40 -0700 (Thu, 16 Sep 2021)
Log Message
Merge r277375 - Crash in WebPageProxy::endColorPicker()
https://bugs.webkit.org/show_bug.cgi?id=225679
Patch by Julian Gonzalez <[email protected]> on 2021-05-12
Reviewed by Ryosuke Niwa.
Make sure that endColorPicker() and didEndColorPicker()
do not both attempt to null-out m_colorPicker.
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::endColorPicker):
(WebKit::WebPageProxy::didEndColorPicker):
Modified Paths
Diff
Modified: releases/WebKitGTK/webkit-2.32/Source/WebKit/ChangeLog (282516 => 282517)
--- releases/WebKitGTK/webkit-2.32/Source/WebKit/ChangeLog 2021-09-16 09:27:38 UTC (rev 282516)
+++ releases/WebKitGTK/webkit-2.32/Source/WebKit/ChangeLog 2021-09-16 09:30:40 UTC (rev 282517)
@@ -1,3 +1,17 @@
+2021-05-12 Julian Gonzalez <[email protected]>
+
+ Crash in WebPageProxy::endColorPicker()
+ https://bugs.webkit.org/show_bug.cgi?id=225679
+
+ Reviewed by Ryosuke Niwa.
+
+ Make sure that endColorPicker() and didEndColorPicker()
+ do not both attempt to null-out m_colorPicker.
+
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::endColorPicker):
+ (WebKit::WebPageProxy::didEndColorPicker):
+
2021-04-27 Chris Dumez <[email protected]>
[IPC Hardening] Make sure IPC::Decoder constructors consistently call markInvalid() when decoding fails
Modified: releases/WebKitGTK/webkit-2.32/Source/WebKit/UIProcess/WebPageProxy.cpp (282516 => 282517)
--- releases/WebKitGTK/webkit-2.32/Source/WebKit/UIProcess/WebPageProxy.cpp 2021-09-16 09:27:38 UTC (rev 282516)
+++ releases/WebKitGTK/webkit-2.32/Source/WebKit/UIProcess/WebPageProxy.cpp 2021-09-16 09:30:40 UTC (rev 282517)
@@ -6134,10 +6134,8 @@
void WebPageProxy::endColorPicker()
{
- if (!m_colorPicker)
- return;
-
- m_colorPicker->endPicker();
+ if (auto colorPicker = std::exchange(m_colorPicker, nullptr))
+ colorPicker->endPicker();
}
void WebPageProxy::didChooseColor(const WebCore::Color& color)
@@ -6150,11 +6148,13 @@
void WebPageProxy::didEndColorPicker()
{
- m_colorPicker = nullptr;
- if (!hasRunningProcess())
- return;
+ if (std::exchange(m_colorPicker, nullptr)) {
+ if (!hasRunningProcess())
+ return;
- send(Messages::WebPage::DidEndColorPicker());
+ send(Messages::WebPage::DidEndColorPicker());
+ }
+
}
#endif
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes