summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--generic/tclFileName.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/generic/tclFileName.c b/generic/tclFileName.c
index 27af639..ec872d0 100644
--- a/generic/tclFileName.c
+++ b/generic/tclFileName.c
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclFileName.c,v 1.74 2006/03/19 23:04:23 vincentdarley Exp $
+ * RCS: @(#) $Id: tclFileName.c,v 1.75 2006/08/30 17:56:57 hobbs Exp $
*/
#include "tclInt.h"
@@ -1828,6 +1828,7 @@ TclGlob(
Tcl_IncrRefCount(savedResultObj);
Tcl_ResetResult(interp);
TclNewObj(filenamesObj);
+ Tcl_IncrRefCount(filenamesObj);
/*
* Now we do the actual globbing, adding filenames as we go to buffer in
@@ -2290,6 +2291,7 @@ DoGlob(
*p = '\0';
TclNewObj(subdirsPtr);
+ Tcl_IncrRefCount(subdirsPtr);
result = Tcl_FSMatchInDirectory(interp, subdirsPtr, pathPtr,
pattern, &dirOnly);
*p = save;