summaryrefslogtreecommitdiff
path: root/source3/smbd/oplock.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2000-04-24 19:23:51 +0000
committerJeremy Allison <jra@samba.org>2000-04-24 19:23:51 +0000
commite82dbfcbe97c79b1c81915ae949bb2b1763970ba (patch)
tree6575dd984ef9bdf74807736d48fe4eee856b96df /source3/smbd/oplock.c
parentb76e942639ab4d75bbf8103f6ea0822466b7615d (diff)
downloadsamba-e82dbfcbe97c79b1c81915ae949bb2b1763970ba.tar.gz
samba-e82dbfcbe97c79b1c81915ae949bb2b1763970ba.tar.bz2
samba-e82dbfcbe97c79b1c81915ae949bb2b1763970ba.zip
Now that fsp's are created on successful file open, the structure member
fsp->open is no longer needed (if an fsp pointer is valid, then it's open :-). NB for Luke, this patch also did not apply to TNG. TNG is not yet identical w.r.t file serving with HEAD. This makes it impossible for me to help maintain TNG. Please fix asap. lib/substitute.c: Removed unused variable (pidstr). Jeremy. (This used to be commit 389b700a26e8a308a0dff6fc038c38068aa0119a)
Diffstat (limited to 'source3/smbd/oplock.c')
-rw-r--r--source3/smbd/oplock.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/smbd/oplock.c b/source3/smbd/oplock.c
index e794d2d923..28ab29d027 100644
--- a/source3/smbd/oplock.c
+++ b/source3/smbd/oplock.c
@@ -1304,10 +1304,10 @@ BOOL attempt_close_oplocked_file(files_struct *fsp)
DEBUG(5,("attempt_close_oplocked_file: checking file %s.\n", fsp->fsp_name));
- if (fsp->open && EXCLUSIVE_OPLOCK_TYPE(fsp->oplock_type) && !fsp->sent_oplock_break && (fsp->fd != -1)) {
+ if (EXCLUSIVE_OPLOCK_TYPE(fsp->oplock_type) && !fsp->sent_oplock_break && (fsp->fd != -1)) {
/* Try and break the oplock. */
if (oplock_break(fsp->dev, fsp->inode, &fsp->open_time, True)) {
- if(!fsp->open) /* Did the oplock break close the file ? */
+ if(file_find_fsp(fsp) == NULL) /* Did the oplock break close the file ? */
return True;
}
}