diff options
Diffstat (limited to 'winsup/cygwin/dir.cc')
-rw-r--r-- | winsup/cygwin/dir.cc | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/winsup/cygwin/dir.cc b/winsup/cygwin/dir.cc index 2ce0488c5..822a5e5fe 100644 --- a/winsup/cygwin/dir.cc +++ b/winsup/cygwin/dir.cc @@ -260,11 +260,7 @@ closedir (DIR *dir) int res = ((fhandler_base *) dir->__fh)->closedir (dir); - /* If the directory has been opened by fdopendir, the descriptor - entry is used elsewhere in the application and must not be removed - from the descriptor table. */ - if (!(dir->__flags & dirent_valid_fd)) - cygheap->fdtab.release (dir->__d_fd); + cygheap->fdtab.release (dir->__d_fd); free (dir->__d_dirname); free (dir->__d_dirent); |