diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2013-06-02 10:22:14 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2013-06-02 10:22:14 +0000 |
commit | a24ad2c346471f3066e051459112341c02a039fc (patch) | |
tree | 6446521c7ebac7e27dcd033815f6a8b1a65da249 /winsup/cygwin/fcntl.cc | |
parent | fa35814af1fe24f596142c993f050f5eb0a74914 (diff) | |
download | cygnal-a24ad2c346471f3066e051459112341c02a039fc.tar.gz cygnal-a24ad2c346471f3066e051459112341c02a039fc.tar.bz2 cygnal-a24ad2c346471f3066e051459112341c02a039fc.zip |
* autoload.cc (CancelSynchronousIo): Define.
* fcntl.cc (fcntl64): Drop handling of locking commands.
* fhandler.h (class fhandler_disk_file): Add mandatory_locking.
(fhandler_disk_file::fcntl): Declare.
(fhandler_disk_file::mand_lock): Declare.
* fhandler_disk_file.cc (fhandler_disk_file::fhandler_disk_file):
Initialize mandatory_locking.
(fhandler_disk_file::fcntl): New method. Handle F_LCK_MANDATORY and
locking commands.
(fhandler_disk_file::dup): Duplicate mandatory_locking. Fix a bug
when duplicating prw_handle failed.
(fhandler_disk_file::fixup_after_fork): Reset mandatory_locking.
* flock.cc (fhandler_disk_file::lock): Add comment.
(struct lock_parms): New struct to pass parameters to blocking_lock_thr
thread function.
(blocking_lock_thr): New thread function.
(fhandler_disk_file::mand_lock): New methof implementing mandatory
locking with Windows semantics.
* ntdll.h (NtLockFile): Declare.
(NtUnlockFile): Declare.
* include/fcntl.h: Fix a comment.
(F_LCK_MANDATORY): Define. Add lengthy comment to explain.
Diffstat (limited to 'winsup/cygwin/fcntl.cc')
-rw-r--r-- | winsup/cygwin/fcntl.cc | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/winsup/cygwin/fcntl.cc b/winsup/cygwin/fcntl.cc index f2c2acc25..ea9a71a5e 100644 --- a/winsup/cygwin/fcntl.cc +++ b/winsup/cygwin/fcntl.cc @@ -1,7 +1,7 @@ /* fcntl.cc: fcntl syscall Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2008, 2009, - 2010, 2011, 2012 Red Hat, Inc. + 2010, 2011, 2012, 2013 Red Hat, Inc. This file is part of Cygwin. @@ -70,15 +70,6 @@ fcntl64 (int fd, int cmd, ...) res = -1; } break; - case F_GETLK: - case F_SETLK: - case F_SETLKW: - { - struct flock *fl = (struct flock *) arg; - fl->l_type &= F_RDLCK | F_WRLCK | F_UNLCK; - res = cfd->lock (cmd, fl); - } - break; default: res = cfd->fcntl (cmd, arg); break; |