From f314884b7de3391ffe4259feb103f74584a58f85 Mon Sep 17 00:00:00 2001 From: Seungha Yang Date: Wed, 1 Feb 2023 23:08:03 +0900 Subject: [PATCH] pluginloader-win32: Zero initialize overlapped struct before use Helper child process might be spawned multiple times for some reason then overlapped struct can hold garbage data. Always clear the struct. Part-of: --- subprojects/gstreamer/gst/gstpluginloader-win32.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/subprojects/gstreamer/gst/gstpluginloader-win32.c b/subprojects/gstreamer/gst/gstpluginloader-win32.c index f85bccab18..2a7b98f203 100644 --- a/subprojects/gstreamer/gst/gstpluginloader-win32.c +++ b/subprojects/gstreamer/gst/gstpluginloader-win32.c @@ -308,6 +308,11 @@ gst_plugin_loader_try_helper (GstPluginLoader * self, gchar * location) goto error; } + loader->overlap.Internal = 0; + loader->overlap.InternalHigh = 0; + loader->overlap.Offset = 0; + loader->overlap.OffsetHigh = 0; + /* Async pipe should return zero */ if (ConnectNamedPipe (loader->pipe, &loader->overlap)) { last_err = GetLastError ();