diff options
author | Pierre Humblet <phumblet@phumblet.no-ip.org> | 2002-12-20 01:48:22 +0000 |
---|---|---|
committer | Pierre Humblet <phumblet@phumblet.no-ip.org> | 2002-12-20 01:48:22 +0000 |
commit | 3ace1da676318a591ee314b784f37661e52cfb75 (patch) | |
tree | d760667ec489471024f49d514c26ddfe78eb75d6 | |
parent | 388aa9941b2432a02513283858cac6c74bb25a0d (diff) | |
download | newlib-3ace1da676318a591ee314b784f37661e52cfb75.zip newlib-3ace1da676318a591ee314b784f37661e52cfb75.tar.gz newlib-3ace1da676318a591ee314b784f37661e52cfb75.tar.bz2 |
2002-12-19 Pierre Humblet <pierre.humblet@ieee.org>
* fhandler.cc (fhandler_base::open): Use "flags" rather than "mode"
in Win9X directory code.
-rw-r--r-- | winsup/cygwin/ChangeLog | 5 | ||||
-rw-r--r-- | winsup/cygwin/fhandler.cc | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 5e2643c..0fd925d 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,8 @@ +2002-12-19 Pierre Humblet <pierre.humblet@ieee.org> + + * fhandler.cc (fhandler_base::open): Use "flags" rather than "mode" + in Win9X directory code. + 2002-12-19 Steve Osborn <bub@io.com> * fhandler.h (line_edit_status): Add a new element. diff --git a/winsup/cygwin/fhandler.cc b/winsup/cygwin/fhandler.cc index f73b8ba..b9d6a12 100644 --- a/winsup/cygwin/fhandler.cc +++ b/winsup/cygwin/fhandler.cc @@ -463,9 +463,9 @@ fhandler_base::open (path_conv *pc, int flags, mode_t mode) { if (!wincap.can_open_directories () && pc && pc->isdir ()) { - if (mode & (O_CREAT | O_EXCL) == (O_CREAT | O_EXCL)) + if (flags & (O_CREAT | O_EXCL) == (O_CREAT | O_EXCL)) set_errno (EEXIST); - else if (mode & (O_WRONLY | O_RDWR)) + else if (flags & (O_WRONLY | O_RDWR)) set_errno (EISDIR); else set_nohandle (true); |