From f11f11f6b5731d7b71eab4558e7fdbdd3b2f98c3 Mon Sep 17 00:00:00 2001 From: dgp Date: Thu, 7 Aug 2008 01:44:29 +0000 Subject: * generic/tclVar.c (TclLookupSimpleVar): Retrieve the number of locals in the localCache from the CallFrame and not from the Proc which may have been mangled by a (broken?) recompile. Backport from the HEAD. --- ChangeLog | 9 ++++++++- generic/tclVar.c | 5 ++--- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index b635bf5..77054c1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,11 @@ -2008-08-04 Don Porter S +2008-08-06 Don Porter + + * generic/tclVar.c (TclLookupSimpleVar): Retrieve the number of + locals in the localCache from the CallFrame and not from the Proc + which may have been mangled by a (broken?) recompile. Backport + from the HEAD. + +2008-08-04 Don Porter * generic/tclExecute.c: Stopped faulty double-logging of errors to * tests/execute.test: stack trace when a compile epoch bump triggers diff --git a/generic/tclVar.c b/generic/tclVar.c index d2314c5..43f0324 100644 --- a/generic/tclVar.c +++ b/generic/tclVar.c @@ -16,7 +16,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclVar.c,v 1.160.2.1 2008/07/21 19:38:20 andreas_kupries Exp $ + * RCS: @(#) $Id: tclVar.c,v 1.160.2.2 2008/08/07 01:44:31 dgp Exp $ */ #include "tclInt.h" @@ -1006,8 +1006,7 @@ TclLookupSimpleVar( } } } else { /* Local var: look in frame varFramePtr. */ - Proc *procPtr = varFramePtr->procPtr; - int localCt = procPtr->numCompiledLocals; + int localCt = varFramePtr->numCompiledLocals; Tcl_Obj **objPtrPtr = &varFramePtr->localCachePtr->varName0; for (i=0 ; i