diff options
| author | apnadkarni <apnmbx-wits@yahoo.com> | 2023-10-04 09:28:58 (GMT) |
|---|---|---|
| committer | apnadkarni <apnmbx-wits@yahoo.com> | 2023-10-04 09:28:58 (GMT) |
| commit | 7d17b3a5420ca3b0f5ef7f6cce6d3d9c636df7ea (patch) | |
| tree | fad2aa87f1d6efc7c7e46aa0e2ceb0335c7ff662 /generic/tclFileName.c | |
| parent | 3e76f1456705e6026804acb175b9d06976c89256 (diff) | |
| parent | 6a7c03014a876e280e451e8070af21e057fb55b6 (diff) | |
| download | tcl-7d17b3a5420ca3b0f5ef7f6cce6d3d9c636df7ea.zip tcl-7d17b3a5420ca3b0f5ef7f6cce6d3d9c636df7ea.tar.gz tcl-7d17b3a5420ca3b0f5ef7f6cce6d3d9c636df7ea.tar.bz2 | |
Merge 8.7 - Fix [9e039ee0b9], [57f144c799] and other zipfs glob issues.
Diffstat (limited to 'generic/tclFileName.c')
| -rw-r--r-- | generic/tclFileName.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/generic/tclFileName.c b/generic/tclFileName.c index 8a58459..c8ace9c 100644 --- a/generic/tclFileName.c +++ b/generic/tclFileName.c @@ -1306,11 +1306,15 @@ Tcl_GlobObjCmd( * We must ensure that we haven't cut off too much, and turned * a valid path like '/' or 'C:/' into an incorrect path like * '' or 'C:'. The way we do this is to add a separator if - * there are none presently in the prefix. + * there are none presently in the prefix. Similar treatment + * for the zipfs volume. */ - if (strpbrk(TclGetString(pathOrDir), "\\/") == NULL) { + const char *temp = TclGetString(pathOrDir); + if (strpbrk(temp, "\\/") == NULL) { Tcl_AppendToObj(pathOrDir, last-1, 1); + } else if (!strcmp(temp, "//zipfs:")) { + Tcl_AppendToObj(pathOrDir, "/", 1); } } |
