timezone: Fix an uninitialized use

GTK ci rightly complains about this when ti builds
GLib as a subproject with -Werror=maybe-uninitialized.

subkey_dynamic_w will be freed without being initialized
when the first goto is taken.
This commit is contained in:
Matthias Clasen 2020-07-31 14:04:21 -04:00
parent 7ce6a01f99
commit 0992978202

View File

@ -831,6 +831,8 @@ rules_from_windows_time_zone (const gchar *identifier,
WCHAR winsyspath[MAX_PATH]; WCHAR winsyspath[MAX_PATH];
gunichar2 *subkey_w, *subkey_dynamic_w; gunichar2 *subkey_w, *subkey_dynamic_w;
subkey_dynamic_w = NULL;
if (GetSystemDirectoryW (winsyspath, MAX_PATH) == 0) if (GetSystemDirectoryW (winsyspath, MAX_PATH) == 0)
return 0; return 0;