You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/app-misc/mc/files/mc-4.8.8-segfault-unowned-t...

23 lines
616 B

fix for mc/mcedit segfault when mc's tempdir doesn't belong to the correct user
https://bugs.gentoo.org/show_bug.cgi?id=473244
https://www.midnight-commander.org/ticket/3021
--- src/main.c
+++ src/main.c
@@ -154,7 +154,4 @@
mc_global.share_data_dir = g_strdup (DATADIR);
-
- /* Set up temporary directory */
- mc_tmpdir ();
}
@@ -299,4 +296,7 @@
vfs_setup_work_dir ();
+ /* Set up temporary directory after VFS initialization */
+ mc_tmpdir ();
+
/* do this after vfs initialization due to mc_setctl() call in mc_setup_by_args() */
if (!mc_setup_by_args (argc, argv, &error))