From 3f3aa2a57dc648ade9083f3b3ad83cce8206b912 Mon Sep 17 00:00:00 2001 From: Denis Vlasenko Date: Mon, 9 Apr 2007 21:35:07 +0000 Subject: make xfunctions optionally longjump instead of exit. use it for making NOFORK more practical. touch: make it a NOFORK applet --- libbb/xfuncs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libbb/xfuncs.c') diff --git a/libbb/xfuncs.c b/libbb/xfuncs.c index 0cf2005..fa4a152 100644 --- a/libbb/xfuncs.c +++ b/libbb/xfuncs.c @@ -476,7 +476,7 @@ void xprint_and_close_file(FILE *file) fflush(stdout); // copyfd outputs error messages for us. if (bb_copyfd_eof(fileno(file), 1) == -1) - exit(xfunc_error_retval); + sleep_and_die(); fclose(file); } -- cgit v1.1