diff options
author | Jeremy Allison <jra@samba.org> | 2001-09-05 22:45:54 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2001-09-05 22:45:54 +0000 |
commit | 49a21ad5ea39d77ba07b6a1ff778177bf10df4ea (patch) | |
tree | ecdb0086e8dff539e46d892081667d41827f4b1b /source/smbd/oplock.c | |
parent | c7d1b06f31550289a864fd09165d3545f207b80e (diff) | |
download | samba-49a21ad5ea39d77ba07b6a1ff778177bf10df4ea.tar.gz samba-49a21ad5ea39d77ba07b6a1ff778177bf10df4ea.tar.xz samba-49a21ad5ea39d77ba07b6a1ff778177bf10df4ea.zip |
Fix I think for the fcntl spinning problem. Re-prioritize so
that oplock break messages get priority over incoming client messages.
Jeremy.
Diffstat (limited to 'source/smbd/oplock.c')
-rw-r--r-- | source/smbd/oplock.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/source/smbd/oplock.c b/source/smbd/oplock.c index 26d193e2c2a..7033eddc163 100644 --- a/source/smbd/oplock.c +++ b/source/smbd/oplock.c @@ -48,6 +48,20 @@ int32 get_number_of_exclusive_open_oplocks(void) return exclusive_oplocks_open; } +/**************************************************************************** + Return True if an oplock message is pending. +****************************************************************************/ + +BOOL oplock_message_waiting(fd_set *fds) +{ + if (koplocks && koplocks->msg_waiting(fds)) + return True; + + if (FD_ISSET(oplock_sock, fds)) + return True; + + return False; +} /**************************************************************************** Read an oplock break message from either the oplock UDP fd or the |