diff options
author | dgp <dgp@users.sourceforge.net> | 2007-03-13 15:59:51 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2007-03-13 15:59:51 (GMT) |
commit | a3ba8079a4c6747f3fd58413e35cd0e2d3adee3d (patch) | |
tree | 4d389b4a06d153cf1f155302bf79074e9fe3ee43 /generic/tclVar.c | |
parent | 9b37ffdd3cd479883df0f3aacbd2e442b40fd5e4 (diff) | |
download | tcl-a3ba8079a4c6747f3fd58413e35cd0e2d3adee3d.zip tcl-a3ba8079a4c6747f3fd58413e35cd0e2d3adee3d.tar.gz tcl-a3ba8079a4c6747f3fd58413e35cd0e2d3adee3d.tar.bz2 |
* generic/tclVar.c (TclArraySet): Re-fetch pointers for the list
* tests/var.test (var-17.1): argument of [array set] each time
through the loop as defense against possible shimmer issues.
[Bug 1669489].
Diffstat (limited to 'generic/tclVar.c')
-rw-r--r-- | generic/tclVar.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/generic/tclVar.c b/generic/tclVar.c index c0dfdc3..b8c608b 100644 --- a/generic/tclVar.c +++ b/generic/tclVar.c @@ -15,7 +15,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.69.2.12 2006/10/05 11:44:03 msofer Exp $ + * RCS: @(#) $Id: tclVar.c,v 1.69.2.13 2007/03/13 15:59:52 dgp Exp $ */ #include "tclInt.h" @@ -3489,6 +3489,14 @@ TclArraySet(interp, arrayNameObj, arrayElemObj) result = TCL_ERROR; break; } + + /* + * The TclPtrSetVar call might have shimmered + * arrayElemObj to another type, so re-fetch + * the pointers for safety. + */ + Tcl_ListObjGetElements(NULL, arrayElemObj, + &elemLen, &elemPtrs); } return result; } |