summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2015-07-07 15:24:07 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2015-07-07 15:24:07 (GMT)
commit649ce6ba5bb32fc38e88fc8f4ac13359651d1d32 (patch)
treec956e3e129f10fa84af19ee55a89a86099fbb85a
parent4a6942aa314339a94bb067b7cc073bad867f77a8 (diff)
parent3cbff9f968ec8d9d215341a263bd40903b8a782e (diff)
downloadtk-649ce6ba5bb32fc38e88fc8f4ac13359651d1d32.zip
tk-649ce6ba5bb32fc38e88fc8f4ac13359651d1d32.tar.gz
tk-649ce6ba5bb32fc38e88fc8f4ac13359651d1d32.tar.bz2
Fix for [805cffb017fde5ba]: segfault via Tk_ConfigureWidget
-rw-r--r--generic/tkOldConfig.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/generic/tkOldConfig.c b/generic/tkOldConfig.c
index d2d864f..87f4987 100644
--- a/generic/tkOldConfig.c
+++ b/generic/tkOldConfig.c
@@ -113,6 +113,10 @@ Tk_ConfigureWidget(
staticSpecs = GetCachedSpecs(interp, specs);
+ for (specPtr = staticSpecs; specPtr->type != TK_CONFIG_END; specPtr++) {
+ specPtr->specFlags &= ~TK_CONFIG_OPTION_SPECIFIED;
+ }
+
/*
* Pass one: scan through all of the arguments, processing those that
* match entries in the specs.
@@ -167,7 +171,6 @@ Tk_ConfigureWidget(
if ((specPtr->specFlags & TK_CONFIG_OPTION_SPECIFIED)
|| (specPtr->argvName == NULL)
|| (specPtr->type == TK_CONFIG_SYNONYM)) {
- specPtr->specFlags &= ~TK_CONFIG_OPTION_SPECIFIED;
continue;
}
if (((specPtr->specFlags & needFlags) != needFlags)
@@ -1126,7 +1129,6 @@ GetCachedSpecs(
specPtr->defValue = Tk_GetUid(specPtr->defValue);
}
}
- specPtr->specFlags &= ~TK_CONFIG_OPTION_SPECIFIED;
}
} else {
cachedSpecs = Tcl_GetHashValue(entryPtr);