diff options
author | Pierre Humblet <phumblet@phumblet.no-ip.org> | 2002-11-01 04:47:29 +0300 |
---|---|---|
committer | Pierre Humblet <phumblet@phumblet.no-ip.org> | 2002-11-01 04:47:29 +0300 |
commit | fe5ba952458a91f04a732302595d229a14fd4a88 (patch) | |
tree | b456d257773fa910109efcf8a505c3ad8549774a /winsup | |
parent | cf157504a84b78ae3874028da620bfc4e89ef0d4 (diff) |
2002-10-31 Pierre Humblet <pierre.humblet@ieee.org>
* fhandler.cc (fhandler_base::open): Verify pc isn't NULL.
Diffstat (limited to 'winsup')
-rw-r--r-- | winsup/cygwin/ChangeLog | 4 | ||||
-rw-r--r-- | winsup/cygwin/fhandler.cc | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index b0cb4b934..ebc3951a6 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,7 @@ +2002-10-31 Pierre Humblet <pierre.humblet@ieee.org> + + * fhandler.cc (fhandler_base::open): Verify pc isn't NULL. + 2002-10-30 Christopher Faylor <cgf@redhat.com> * include/cygwin/version.h: Bump DLL minor number. diff --git a/winsup/cygwin/fhandler.cc b/winsup/cygwin/fhandler.cc index fccbb361e..ffb67b6cc 100644 --- a/winsup/cygwin/fhandler.cc +++ b/winsup/cygwin/fhandler.cc @@ -442,7 +442,7 @@ fhandler_base::open (path_conv *pc, int flags, mode_t mode) if (x == INVALID_HANDLE_VALUE) { - if (pc->isdir () && !wincap.can_open_directories ()) + if (!wincap.can_open_directories () && pc && pc->isdir ()) { if (mode & (O_CREAT | O_EXCL) == (O_CREAT | O_EXCL)) set_errno (EEXIST); |