summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixFCmd.c
diff options
context:
space:
mode:
authorkjnash <k.j.nash@usa.net>2018-09-15 18:41:23 (GMT)
committerkjnash <k.j.nash@usa.net>2018-09-15 18:41:23 (GMT)
commitd24a3eb2babc2868c7935f0815288c9ab02c3880 (patch)
tree2ee6809fdc6448db53cbd12bb6e35df4fe077503 /unix/tclUnixFCmd.c
parent754bb107b4100f394d445d589dddc94e59dd2d04 (diff)
parent9a15a1b58648809ffb208eaa00cd20af4784050d (diff)
downloadtcl-d24a3eb2babc2868c7935f0815288c9ab02c3880.zip
tcl-d24a3eb2babc2868c7935f0815288c9ab02c3880.tar.gz
tcl-d24a3eb2babc2868c7935f0815288c9ab02c3880.tar.bz2
merge 8.6
Diffstat (limited to 'unix/tclUnixFCmd.c')
-rw-r--r--unix/tclUnixFCmd.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/unix/tclUnixFCmd.c b/unix/tclUnixFCmd.c
index a1a409e..ae20ee0 100644
--- a/unix/tclUnixFCmd.c
+++ b/unix/tclUnixFCmd.c
@@ -369,13 +369,13 @@ DoRenameFile(
if (errno == EINVAL && haveRealpath) {
char srcPath[MAXPATHLEN], dstPath[MAXPATHLEN];
- DIR *dirPtr;
+ TclDIR *dirPtr;
Tcl_DirEntry *dirEntPtr;
if ((Realpath((char *) src, srcPath) != NULL) /* INTL: Native. */
&& (Realpath((char *) dst, dstPath) != NULL) /* INTL: Native */
&& (strncmp(srcPath, dstPath, strlen(srcPath)) != 0)) {
- dirPtr = opendir(dst); /* INTL: Native. */
+ dirPtr = TclOSopendir(dst); /* INTL: Native. */
if (dirPtr != NULL) {
while (1) {
dirEntPtr = TclOSreaddir(dirPtr); /* INTL: Native. */
@@ -385,11 +385,11 @@ DoRenameFile(
if ((strcmp(dirEntPtr->d_name, ".") != 0) &&
(strcmp(dirEntPtr->d_name, "..") != 0)) {
errno = EEXIST;
- closedir(dirPtr);
+ TclOSclosedir(dirPtr);
return TCL_ERROR;
}
}
- closedir(dirPtr);
+ TclOSclosedir(dirPtr);
}
}
errno = EINVAL;
@@ -965,7 +965,7 @@ TraverseUnixTree(
#ifndef HAVE_FTS
int numProcessed = 0;
Tcl_DirEntry *dirEntPtr;
- DIR *dirPtr;
+ TclDIR *dirPtr;
#else
const char *paths[2] = {NULL, NULL};
FTS *fts = NULL;
@@ -990,7 +990,7 @@ TraverseUnixTree(
errorPtr);
}
#ifndef HAVE_FTS
- dirPtr = opendir(source); /* INTL: Native. */
+ dirPtr = TclOSopendir(source); /* INTL: Native. */
if (dirPtr == NULL) {
/*
* Can't read directory
@@ -1002,7 +1002,7 @@ TraverseUnixTree(
result = traverseProc(sourcePtr, targetPtr, &statBuf, DOTREE_PRED,
errorPtr);
if (result != TCL_OK) {
- closedir(dirPtr);
+ TclOSclosedir(dirPtr);
return result;
}
@@ -1052,11 +1052,11 @@ TraverseUnixTree(
* NULL-return that may a symptom of a buggy readdir.
*/
- rewinddir(dirPtr);
+ TclOSrewinddir(dirPtr);
numProcessed = 0;
}
}
- closedir(dirPtr);
+ TclOSclosedir(dirPtr);
/*
* Strip off the trailing slash we added