diff options
author | andreas_kupries <andreas_kupries@noemail.net> | 2008-04-17 19:14:17 (GMT) |
---|---|---|
committer | andreas_kupries <andreas_kupries@noemail.net> | 2008-04-17 19:14:17 (GMT) |
commit | 6f045d19badbde7ce1249ec75d12be8f69b2d85e (patch) | |
tree | a12e5be99c025aa9ba9b569eac8b524673bf46e5 /generic/tclCompExpr.c | |
parent | fb0f99cad68ea93b00314e463de521f9fc628bab (diff) | |
download | tcl-6f045d19badbde7ce1249ec75d12be8f69b2d85e.zip tcl-6f045d19badbde7ce1249ec75d12be8f69b2d85e.tar.gz tcl-6f045d19badbde7ce1249ec75d12be8f69b2d85e.tar.bz2 |
* generic/tclCompExpr.c (CompileMathFuncCall): Added
* tests/compile.test (compile-16.0): Tcl_ResetResult before
appending error message, to clear out possible sharing. Added test
case demonstrating the crash (abort on shared object) without the
fix.
FossilOrigin-Name: 5ea42286b6ad44d1db19480db8fc1fabca5e6b86
Diffstat (limited to 'generic/tclCompExpr.c')
-rw-r--r-- | generic/tclCompExpr.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/generic/tclCompExpr.c b/generic/tclCompExpr.c index 3ff749b..8c66f5c 100644 --- a/generic/tclCompExpr.c +++ b/generic/tclCompExpr.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclCompExpr.c,v 1.13.2.3 2006/11/28 22:20:00 andreas_kupries Exp $ + * RCS: @(#) $Id: tclCompExpr.c,v 1.13.2.4 2008/04/17 19:14:20 andreas_kupries Exp $ */ #include "tclInt.h" @@ -852,6 +852,7 @@ CompileMathFuncCall(exprTokenPtr, funcName, infoPtr, envPtr, endPtrPtr) code = TCL_OK; hPtr = Tcl_FindHashEntry(&iPtr->mathFuncTable, funcName); if (hPtr == NULL) { + Tcl_ResetResult(interp); Tcl_AppendStringsToObj(Tcl_GetObjResult(interp), "unknown math function \"", funcName, "\"", (char *) NULL); code = TCL_ERROR; |