From: Ben Pfaff Date: Thu, 12 Jan 2006 17:04:09 +0000 (+0000) Subject: Clean up temp files on signal. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a6743379d7959d012eb6db2ececc01ece70642d7;p=pintos-anon Clean up temp files on signal. --- diff --git a/src/utils/pintos b/src/utils/pintos index afd0ec2..f993968 100755 --- a/src/utils/pintos +++ b/src/utils/pintos @@ -677,10 +677,11 @@ sub xsystem { # relay_signal($pid, $signal) # # Relays $signal to $pid and then reinvokes it for us with the default -# handler. +# handler. Also cleans up temporary files. sub relay_signal { my ($pid, $signal) = @_; kill $signal, $pid; + File::Temp::cleanup(); $SIG{$signal} = 'DEFAULT'; kill $signal, getpid (); }