From: Alistair Leslie-Hughes <leslie_alistair(a)hotmail.com> --- dlls/odbccp32/odbccp32.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dlls/odbccp32/odbccp32.c b/dlls/odbccp32/odbccp32.c index 62e35e85f75..95bfb90781e 100644 --- a/dlls/odbccp32/odbccp32.c +++ b/dlls/odbccp32/odbccp32.c @@ -1003,6 +1003,7 @@ static void write_registry_values(const WCHAR *regkey, const WCHAR *driver, cons value = malloc(len * sizeof(WCHAR)); if(!value) { + RegCloseKey(hkeydriver); ERR("Out of memory\n"); return; } @@ -1015,6 +1016,7 @@ static void write_registry_values(const WCHAR *regkey, const WCHAR *driver, cons value = calloc(1, (lstrlenW(divider)+1) * sizeof(WCHAR)); if(!value) { + RegCloseKey(hkeydriver); ERR("Out of memory\n"); return; } -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/5806