1 /* aNetHack 0.0.1 vmsmisc.c $ANH-Date: 1432512789 2015/05/25 00:13:09 $ $ANH-Branch: master $:$ANH-Revision: 1.10 $ */
2 /* aNetHack may be freely redistributed. See license for details. */
9 int debuggable
= 0; /* 1 if we can debug or show a call trace */
11 void FDECL(vms_exit
, (int));
12 void NDECL(vms_abort
);
14 /* first arg should be unsigned long but <lib$routines.h> has unsigned int */
15 extern void VDECL(lib$signal
, (unsigned, ...));
17 /* terminate, converting Unix-style exit code into VMS status code */
22 /* convert non-zero to failure, zero to success */
23 exit(status
? (SS$_ABORT
| STS$M_INHIB_MSG
) : SS$_NORMAL
);
27 /* put the user into the debugger; used for abort() when in wizard mode */
32 lib$
signal(SS$_DEBUG
);
34 /* we'll get here if the debugger isn't available, or if the user
35 uses GO to resume execution instead of EXIT to quit */
36 vms_exit(2); /* don't return to caller (2==arbitrary non-zero) */
41 * Caveat: the VERYOLD_VMS configuration hasn't been tested in many years.