mirror of
https://github.com/flatpak/flatpak.git
synced 2026-03-26 10:54:59 -04:00
flatpak-dir: Fix a memory leak when installing a package
The path was clobbered make the g_autoptr no work Signed-off-by: Hubert Figuière <hub@figuiere.net>
This commit is contained in:
committed by
Simon McVittie
parent
739065e432
commit
9d60df4d0c
@@ -1952,6 +1952,8 @@ flatpak_ensure_system_user_cache_dir_location (GError **error)
|
||||
(st_buf.st_mode & 0777) == 0755)
|
||||
return g_file_new_for_path (path);
|
||||
|
||||
g_clear_pointer (&path, g_free);
|
||||
|
||||
path = g_strdup ("/var/tmp/flatpak-cache-XXXXXX");
|
||||
|
||||
if (g_mkdtemp_full (path, 0755) == NULL)
|
||||
|
||||
Reference in New Issue
Block a user