"Fossies" - the Fresh Open Source Software Archive 
Member "xorriso-1.5.4/libburn/cleanup.h" (30 Jan 2021, 1178 Bytes) of package /linux/misc/xorriso-1.5.4.pl02.tar.gz:
As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style:
standard) with prefixed line numbers and
code folding option.
Alternatively you can here
view or
download the uninterpreted source code file.
For more information about "cleanup.h" see the
Fossies "Dox" file reference documentation.
1 /*
2 cleanup.c , Copyright 2006 Thomas Schmitt <scdbackup@gmx.net>
3
4 A signal handler which cleans up an application and exits.
5
6 Provided under GPLv2+ within GPL projects, BSD license elsewise.
7 */
8
9 #ifndef Cleanup_includeD
10 #define Cleanup_includeD 1
11
12
13 /** Layout of an application provided cleanup function using an application
14 provided handle as first argument and the signal number as second
15 argument. The third argument is a flag bit field with no defined bits yet.
16 If the handler returns 2 or -2 then it has delegated exit() to some other
17 instance and the Cleanup handler shall return rather than exit.
18 */
19 typedef int (*Cleanup_app_handler_T)(void *, int, int);
20
21
22 /** Establish exiting signal handlers on (hopefully) all signals that are
23 not ignored by default or non-catchable.
24 @param handle Opaque object which knows how to cleanup application
25 @param handler Function which uses handle to perform application cleanup
26 @param flag Control Bitfield
27 bit0= reset to default signal handling
28 */
29 int Cleanup_set_handlers(void *handle, Cleanup_app_handler_T handler,
30 int flag);
31
32
33 #endif /* ! Cleanup_includeD */
34