Fix bug #13079 on MS-Windows with temp files not being deleted.
authorEli Zaretskii <eliz@gnu.org>
Sat, 15 Dec 2012 13:38:21 +0000 (15:38 +0200)
committerEli Zaretskii <eliz@gnu.org>
Sat, 15 Dec 2012 13:38:21 +0000 (15:38 +0200)
commitb07286179ec721bc44a7e32111318fb325789fe1
tree605b9464822cc82d4b9b2e437c6711622142c7d5
parent279f9b06fd693b67d1178cdb5ad1ecf513d199ad
Fix bug #13079 on MS-Windows with temp files not being deleted.

 src/w32.h (_child_process): New members input_file and
 pending_deletion.
 (register_child): First argument is now pid_t.
 (record_infile, record_pending_deletion): New prototypes.
 src/w32proc.c (new_child): Initialize input_file and
 pending_deletion members of the child.
 (delete_child): Delete the child's temporary input file, if any,
 that is pending deletion.
 (register_child): First argument is now pid_t.
 (record_infile, record_pending_deletion): New functions.
 (reap_subprocess): Fix a typo in DebPrint string.
 (sys_spawnve, sys_kill): Use pid_t for PID arguments.
 src/fileio.c (internal_delete_file): Return an int again: non-zero
 if delete-file succeeds, zero otherwise.
 src/lisp.h (internal_delete_file): Adjust prototype.
 src/callproc.c (Fcall_process): Don't overwrite infile with result
 of DECODE_FILE.
 [WINDOWSNT] If BUFFER is an integer, i.e. we are launching an
 asynchronous subprocess, record the name of the input file name,
 if any.
 (delete_temp_file) [WINDOWSNT]: If internal_delete_file fails to
 delete the file, record it as pending deletion when the subprocess
 exits.

 nt/inc/ms-w32.h (sys_unlink): Provide prototype.
nt/inc/ms-w32.h
src/ChangeLog
src/callproc.c
src/fileio.c
src/lisp.h
src/w32.h
src/w32proc.c