Skip to content
Snippets Groups Projects
Commit b3cacf82 authored by Simon McVittie's avatar Simon McVittie
Browse files

wrap: Clean up overrides directory before running the game


This means we won't leak resources if we're terminated abruptly.

Signed-off-by: default avatarSimon McVittie <smcv@collabora.com>
parent 10512871
No related branches found
No related tags found
No related merge requests found
......@@ -2153,6 +2153,17 @@ main (int argc,
flatpak_bwrap_finish (bwrap);
/* Clean up temporary directory before running our long-running process */
if (tmpdir != NULL &&
!glnx_shutil_rm_rf_at (-1, tmpdir, NULL, error))
{
g_warning ("Unable to delete temporary directory: %s",
local_error->message);
g_clear_error (&local_error);
}
g_clear_pointer (&tmpdir, g_free);
/* flatpak_bwrap_finish did this */
g_assert (g_ptr_array_index (bwrap->argv, bwrap->argv->len - 1) == NULL);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment