From f5143405f181752c679f740e9c06f2a31d8e9545 Mon Sep 17 00:00:00 2001 From: Max Crofts Date: Fri, 7 Apr 2017 15:18:28 +1000 Subject: [PATCH] Add missing RegCloseKey to Sys_SteamPath --- code/sys/sys_win32.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/code/sys/sys_win32.c b/code/sys/sys_win32.c index da7241a7..6bf0828c 100644 --- a/code/sys/sys_win32.c +++ b/code/sys/sys_win32.c @@ -148,6 +148,8 @@ char *Sys_SteamPath( void ) pathLen = MAX_OSPATH; if (RegQueryValueEx(steamRegKey, "InstallLocation", NULL, NULL, (LPBYTE)steamPath, &pathLen)) steamPath[0] = '\0'; + + RegCloseKey(steamRegKey); } #endif @@ -161,6 +163,8 @@ char *Sys_SteamPath( void ) if (steamPath[0]) finishPath = qtrue; + + RegCloseKey(steamRegKey); } #endif