From 366315077e870bb2cdc9047e8515516f89a9f842 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafa=C5=82=20Dzi=C4=99giel?= Date: Sun, 23 Feb 2025 17:28:21 +0100 Subject: [PATCH] clapper-app: Use user data dir for storing pipeline exports System tmp directory does not work within containers such as Flatpak for our usage with file launcher, so make our own temp in app data dir --- src/bin/clapper-app/clapper-app-utils.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/bin/clapper-app/clapper-app-utils.c b/src/bin/clapper-app/clapper-app-utils.c index 3da4a28d..447696ed 100644 --- a/src/bin/clapper-app/clapper-app-utils.c +++ b/src/bin/clapper-app/clapper-app-utils.c @@ -542,8 +542,10 @@ clapper_app_utils_make_element (const gchar *string) static inline GFile * _get_tmp_dir (const gchar *subdir) { + /* XXX: System tmp directory does not work within containers such as Flatpak + * for our usage with file launcher, so make our own temp in app data dir */ return g_file_new_build_filename ( - g_get_tmp_dir (), "." CLAPPER_APP_ID, subdir, NULL); + g_get_user_data_dir (), CLAPPER_APP_ID, "tmp", subdir, NULL); } #ifdef HAVE_GRAPHVIZ