diff options
author | stanton <stanton@noemail.net> | 1999-06-16 21:56:32 (GMT) |
---|---|---|
committer | stanton <stanton@noemail.net> | 1999-06-16 21:56:32 (GMT) |
commit | 9a2868548e6e877cab6322f260759b26ca89c211 (patch) | |
tree | bb7b7f3564458026a1797c83e0f80bea28e41fa4 /generic | |
parent | cd1eab47822bc5a64f70720689ef9824c1ecdd81 (diff) | |
download | tcl-9a2868548e6e877cab6322f260759b26ca89c211.zip tcl-9a2868548e6e877cab6322f260759b26ca89c211.tar.gz tcl-9a2868548e6e877cab6322f260759b26ca89c211.tar.bz2 |
* tests/execute.test:
* generic/tclExecute.c (TclExecuteByteCode): Fixed crash caused by
a bug in INST_LOAD_SCALAR1 where the scalar index was read as
a signed 1 byte value instead of unsigned. [Bug: 2243]
FossilOrigin-Name: 82d723f770d69aadb94ac75e7cb98ddff8cdd842
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclExecute.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/generic/tclExecute.c b/generic/tclExecute.c index 4378d34..c7e05a4 100644 --- a/generic/tclExecute.c +++ b/generic/tclExecute.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: tclExecute.c,v 1.6 1999/04/16 00:46:46 stanton Exp $ + * RCS: @(#) $Id: tclExecute.c,v 1.7 1999/06/16 21:56:33 stanton Exp $ */ #include "tclInt.h" @@ -1052,7 +1052,7 @@ TclExecuteByteCode(interp, codePtr) case INST_LOAD_SCALAR1: #ifdef TCL_COMPILE_DEBUG - opnd = TclGetInt1AtPtr(pc+1); + opnd = TclGetUInt1AtPtr(pc+1); DECACHE_STACK_INFO(); valuePtr = TclGetIndexedScalar(interp, opnd, /*leaveErrorMsg*/ 1); @@ -1067,8 +1067,8 @@ TclExecuteByteCode(interp, codePtr) TRACE_WITH_OBJ(("%u => ", opnd), valuePtr); #else /* TCL_COMPILE_DEBUG */ DECACHE_STACK_INFO(); - valuePtr = TclGetIndexedScalar(interp, TclGetInt1AtPtr(pc+1), - /*leaveErrorMsg*/ 1); + opnd = TclGetUInt1AtPtr(pc+1); + valuePtr = TclGetIndexedScalar(interp, opnd, /*leaveErrorMsg*/ 1); CACHE_STACK_INFO(); if (valuePtr == NULL) { result = TCL_ERROR; |