Title: [284983] trunk/Source/WebKit
- Revision
- 284983
- Author
- ape...@igalia.com
- Date
- 2021-10-28 09:04:44 -0700 (Thu, 28 Oct 2021)
Log Message
[WPE][Qt] String memory leak in WPEQtView.cpp
https://bugs.webkit.org/show_bug.cgi?id=232435
Reviewed by Michael Catanzaro.
No new tests needed.
* UIProcess/API/wpe/qt/WPEQtView.cpp:
(jsAsyncReadyCallback): Remove unneeded usage of g_strdup(), and replace direct usage
of the QString constructor with QString::fromUtf8(), which better indicates that the
call will copy the string contents.
Modified Paths
Diff
Modified: trunk/Source/WebKit/ChangeLog (284982 => 284983)
--- trunk/Source/WebKit/ChangeLog 2021-10-28 16:04:41 UTC (rev 284982)
+++ trunk/Source/WebKit/ChangeLog 2021-10-28 16:04:44 UTC (rev 284983)
@@ -1,3 +1,17 @@
+2021-10-28 Adrian Perez de Castro <ape...@igalia.com>
+
+ [WPE][Qt] String memory leak in WPEQtView.cpp
+ https://bugs.webkit.org/show_bug.cgi?id=232435
+
+ Reviewed by Michael Catanzaro.
+
+ No new tests needed.
+
+ * UIProcess/API/wpe/qt/WPEQtView.cpp:
+ (jsAsyncReadyCallback): Remove unneeded usage of g_strdup(), and replace direct usage
+ of the QString constructor with QString::fromUtf8(), which better indicates that the
+ call will copy the string contents.
+
2021-10-28 Youenn Fablet <you...@apple.com>
[ Mac wk1 ] 2 media-capabilities/webrtc tests are flaky failures
Modified: trunk/Source/WebKit/UIProcess/API/wpe/qt/WPEQtView.cpp (284982 => 284983)
--- trunk/Source/WebKit/UIProcess/API/wpe/qt/WPEQtView.cpp 2021-10-28 16:04:41 UTC (rev 284982)
+++ trunk/Source/WebKit/UIProcess/API/wpe/qt/WPEQtView.cpp 2021-10-28 16:04:44 UTC (rev 284983)
@@ -432,7 +432,7 @@
qWarning("Error running _javascript_: %s", jsc_exception_get_message(exception));
jsc_context_clear_exception(context);
} else
- variant.setValue(QString(g_strdup(strValue.get())));
+ variant.setValue(QString::fromUtf8(strValue.get()));
}
args.append(engine->toScriptValue(variant));
data->callback.call(args);
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes