2 * End-of-run cleanup helper code used by cleanup.c.
4 * Copyright (C) 2006-2007 Wayne Davison
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 3 as
8 * published by the Free Software Foundation.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License along
16 * with this program; if not, visit the http://fsf.org website.
19 /* This is included by cleanup.c multiple times, once for every segement in
20 * the _exit_cleanup() code. This produces the next "case N:" statement in
21 * sequence and increments the cleanup_step variable by 1. This ensures that
22 * our case statements never get out of whack due to added/removed steps. */
24 #if !defined EXIT_CLEANUP_CASE_0
25 #define EXIT_CLEANUP_CASE_0
27 #elif !defined EXIT_CLEANUP_CASE_1
28 #define EXIT_CLEANUP_CASE_1
30 #elif !defined EXIT_CLEANUP_CASE_2
31 #define EXIT_CLEANUP_CASE_2
33 #elif !defined EXIT_CLEANUP_CASE_3
34 #define EXIT_CLEANUP_CASE_3
36 #elif !defined EXIT_CLEANUP_CASE_4
37 #define EXIT_CLEANUP_CASE_4
39 #elif !defined EXIT_CLEANUP_CASE_5
40 #define EXIT_CLEANUP_CASE_5
42 #elif !defined EXIT_CLEANUP_CASE_6
43 #define EXIT_CLEANUP_CASE_6
45 #elif !defined EXIT_CLEANUP_CASE_7
46 #define EXIT_CLEANUP_CASE_7
48 #elif !defined EXIT_CLEANUP_CASE_8
49 #define EXIT_CLEANUP_CASE_8
51 #elif !defined EXIT_CLEANUP_CASE_9
52 #define EXIT_CLEANUP_CASE_9
54 #elif !defined EXIT_CLEANUP_CASE_10
55 #define EXIT_CLEANUP_CASE_10
57 #elif !defined EXIT_CLEANUP_CASE_11
58 #define EXIT_CLEANUP_CASE_11
60 #elif !defined EXIT_CLEANUP_CASE_12
61 #define EXIT_CLEANUP_CASE_12
63 #elif !defined EXIT_CLEANUP_CASE_13
64 #define EXIT_CLEANUP_CASE_13
66 #elif !defined EXIT_CLEANUP_CASE_14
67 #define EXIT_CLEANUP_CASE_14
69 #elif !defined EXIT_CLEANUP_CASE_15
70 #define EXIT_CLEANUP_CASE_15
72 #elif !defined EXIT_CLEANUP_CASE_16
73 #define EXIT_CLEANUP_CASE_16
76 #error Need to add more case statements!