* ext.c (exec_extension) [HAVE_X]: Free file_name. Add comment

explaining why it cannot be unlinked there.
This commit is contained in:
Pavel Roskin 2001-07-08 21:34:55 +00:00
parent 4f992c2fd3
commit 3f25e54361
2 changed files with 13 additions and 2 deletions

View File

@ -1,3 +1,8 @@
2001-07-08 Pavel Roskin <proski@gnu.org>
* ext.c (exec_extension) [HAVE_X]: Free file_name. Add comment
explaining why it cannot be unlinked there.
2001-07-06 Pavel Roskin <proski@gnu.org>
* ext.c (exec_extension): Unlink temporary file earlier if it's

View File

@ -311,12 +311,18 @@ exec_extension (const char *filename, const char *data, char **drops, int *move_
}
#endif /* !HAVE_X */
}
#ifndef PORT_DOES_BACKGROUND_EXEC
if (file_name) {
/*
* GNOME edition executes file_name in a separate process.
* Cannot remove it here because it may happen before the
* child has executed it. my_system() in gutil.c has
* (currently defunct) code to remove temporary files.
*/
#ifndef HAVE_X
unlink (file_name);
#endif /* !HAVE_X */
g_free (file_name);
}
#endif
if (localcopy) {
mc_stat (localcopy, &mystat);
mc_ungetlocalcopy (filename, localcopy, localmtime != mystat.st_mtime);