Merge branch '2891-2892-win32-leaks' into 'main'

gwin32: Fix two minor string leaks

Closes #2891 and #2892

See merge request GNOME/glib!3222
This commit is contained in:
Philip Withnall 2023-01-23 12:54:16 +00:00
commit 20c4fcb2a7
2 changed files with 3 additions and 0 deletions

View File

@ -406,6 +406,8 @@ g_win32_mount_get_icon (GMount *mount)
{ {
win32_mount->icon = g_themed_icon_new_with_default_fallbacks (_win32_drive_type_to_icon (win32_mount->drive_type, FALSE)); win32_mount->icon = g_themed_icon_new_with_default_fallbacks (_win32_drive_type_to_icon (win32_mount->drive_type, FALSE));
} }
g_free (wfn);
} }
return g_object_ref (win32_mount->icon); return g_object_ref (win32_mount->icon);

View File

@ -316,6 +316,7 @@ g_win32_fs_monitor_init (GWin32FSMonitorPrivate *monitor,
wcsdup (wshortname); wcsdup (wshortname);
} }
g_free (wfullpath);
g_free (fullpath); g_free (fullpath);
} }
else else