summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--generic/tclEnv.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/generic/tclEnv.c b/generic/tclEnv.c
index 4a48f65..40ced17 100644
--- a/generic/tclEnv.c
+++ b/generic/tclEnv.c
@@ -727,10 +727,9 @@ TclFinalizeEnvironment(void)
* free all strings in the cache.
*/
- size_t i;
-
if (env.cache) {
#ifdef PURIFY
+ int i;
for (i = 0; i < env.cacheSize; i++) {
ckfree(env.cache[i]);
}
@@ -738,11 +737,11 @@ TclFinalizeEnvironment(void)
ckfree(env.cache);
env.cache = NULL;
env.cacheSize = 0;
+#ifndef USE_PUTENV
if ((env.ourEnviron != NULL)) {
ckfree(env.ourEnviron);
env.ourEnviron = NULL;
}
-#ifndef USE_PUTENV
env.ourEnvironSize = 0;
#endif
}