diff options
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclCompile.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/generic/tclCompile.c b/generic/tclCompile.c index 24a8693..d461309 100644 --- a/generic/tclCompile.c +++ b/generic/tclCompile.c @@ -11,7 +11,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclCompile.c,v 1.31 2002/01/25 20:40:55 dgp Exp $ + * RCS: @(#) $Id: tclCompile.c,v 1.32 2002/03/15 15:39:06 dkf Exp $ */ #include "tclInt.h" @@ -1239,10 +1239,11 @@ TclCompileTokens(interp, tokenPtr, count, envPtr) code = TclCompileTokens(interp, tokenPtr+2, tokenPtr->numComponents-1, envPtr); if (code != TCL_OK) { - sprintf(buffer, + char errorBuffer[150]; + sprintf(errorBuffer, "\n (parsing index for array \"%.*s\")", ((nameBytes > 100)? 100 : nameBytes), name); - Tcl_AddObjErrorInfo(interp, buffer, -1); + Tcl_AddObjErrorInfo(interp, errorBuffer, -1); goto error; } if (localVar < 0) { |