[PATCH] quartz: Fix memory leaks on error paths in FilterMapper3_RegisterFilter (cppcheck)
Signed-off-by: Alex Henrie <alexhenrie24(a)gmail.com> --- dlls/quartz/filtermapper.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dlls/quartz/filtermapper.c b/dlls/quartz/filtermapper.c index 230273891d4..a95f0ca7832 100644 --- a/dlls/quartz/filtermapper.c +++ b/dlls/quartz/filtermapper.c @@ -894,12 +894,16 @@ static HRESULT WINAPI FilterMapper3_RegisterFilter(IFilterMapper3 *iface, if (FAILED(hr = CoCreateInstance(&CLSID_CDeviceMoniker, NULL, CLSCTX_INPROC, &IID_IParseDisplayName, (void **)&parser))) + { + free(display_name); return hr; + } if (FAILED(hr = IParseDisplayName_ParseDisplayName(parser, NULL, display_name, &eaten, &moniker))) { ERR("Failed to parse display name, hr %#x.\n", hr); IParseDisplayName_Release(parser); + free(display_name); return hr; } @@ -909,6 +913,7 @@ static HRESULT WINAPI FilterMapper3_RegisterFilter(IFilterMapper3 *iface, { ERR("Failed to get property bag, hr %#x.\n", hr); IMoniker_Release(moniker); + free(display_name); return hr; } -- 2.34.1
Hi, While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check? Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=104239 Your paranoid android. === debian11 (32 bit WoW report) === quartz: filtergraph: Timeout
participants (3)
-
Alex Henrie -
Marvin -
Zebediah Figura (she/her)