3 * Routines to exit the game orderly on error, with cleaning up and a somewhat
12 /* Set "f" as the cleanup function to be called on exit. */
13 extern void set_cleanup_func(void (* f)());
15 /* If "err" == 0, do nothing. Else, clean up and exit with an error message that
16 * consists, first, of "msg" or (if "msg" is a NULL pointer) a generic "Details
17 * unknown", secondly of "err" as the "internal error code", and thirdly of
18 * errno if it is non-zero.
20 extern void exit_err(int err, char * msg);
22 /* Do exit_err() with "msg" as: "Trouble in ".parent." with ".child."." */
23 extern void exit_trouble(int err, char * parent, char * child);