git.samba.org
/
rsync.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Make exit_cleanup() use _exit() if called from a signal handler.
[rsync.git]
/
cleanup.c
diff --git
a/cleanup.c
b/cleanup.c
index 8cde03896f3150037fb92cddaf03b1386049148b..51130cafa570b931dcd6a393e079e46e55beef82 100644
(file)
--- a/
cleanup.c
+++ b/
cleanup.c
@@
-34,6
+34,7
@@
extern int output_needs_newline;
extern char *partial_dir;
extern char *logfile_name;
+int called_from_signal_handler = 0;
BOOL shutting_down = False;
BOOL flush_ok_after_signal = False;
@@
-260,6
+261,8
@@
NORETURN void _exit_cleanup(int code, const char *file, int line)
break;
}
+ if (called_from_signal_handler)
+ _exit(exit_code);
exit(exit_code);
}