diff options
Diffstat (limited to 'generic/tclPanic.c')
-rw-r--r-- | generic/tclPanic.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/generic/tclPanic.c b/generic/tclPanic.c index 4e4b06c..5b9125e 100644 --- a/generic/tclPanic.c +++ b/generic/tclPanic.c @@ -12,10 +12,11 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclPanic.c,v 1.3 2001/06/08 20:06:11 dgp Exp $ + * RCS: @(#) $Id: tclPanic.c,v 1.4 2001/06/17 03:48:19 dgp Exp $ */ #include "tclInt.h" +#include "tclPort.h" /* * The panicProc variable contains a pointer to an application @@ -24,6 +25,14 @@ static Tcl_PanicProc *panicProc = NULL; +/* + * The platformPanicProc variable contains a pointer to a platform + * specific panic procedure, if any. ( TclpPanic may be NULL via + * a macro. ) + */ + +static Tcl_PanicProc * CONST platformPanicProc = TclpPanic; + /* *---------------------------------------------------------------------- @@ -86,6 +95,9 @@ Tcl_PanicVA (format, argList) if (panicProc != NULL) { (void) (*panicProc)(format, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8); + } else if (platformPanicProc != NULL) { + (void) (*platformPanicProc)(format, arg1, arg2, arg3, arg4, + arg5, arg6, arg7, arg8); } else { (void) fprintf(stderr, format, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8); |