From 0f0a7dc99d2e837828b14035817f2428437aa1c6 Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Mon, 2 Apr 2001 14:35:17 +0000 Subject: [PATCH] * fhandler.cc (fhandler_disk_file::open): Avoid checking a magic number of a directory. --- winsup/cygwin/ChangeLog | 5 +++++ winsup/cygwin/fhandler.cc | 1 + 2 files changed, 6 insertions(+) diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 60fb23615..f98a93667 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,8 @@ +2001-04-02 Kazuhiro Fujieda + + * fhandler.cc (fhandler_disk_file::open): Avoid checking a magic + number of a directory. + Mon Apr 2 00:24:08 2001 Christopher Faylor * shared_info.h (mount_info): Remove mnt_ elements. diff --git a/winsup/cygwin/fhandler.cc b/winsup/cygwin/fhandler.cc index adeec56a5..73fe3f554 100644 --- a/winsup/cygwin/fhandler.cc +++ b/winsup/cygwin/fhandler.cc @@ -1264,6 +1264,7 @@ fhandler_disk_file::open (path_conv& real_path, int flags, mode_t mode) extern BOOL allow_ntea; if (real_path.isdisk () + && !(real_path.file_attributes () & FILE_ATTRIBUTE_DIRECTORY) && (real_path.exec_state () == dont_know_if_executable) && !allow_ntea && (!allow_ntsec || !real_path.has_acls ())) {