From dfcc4115ddc7c3bf7a69d7eb747c096cd217b8a6 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Wed, 2 Dec 2009 18:06:40 -0800 Subject: Remove unneeded argument from can_set_delete_on_close(). Ensure can_set_delete_on_close() is correctly called before any setting of the disposition bit (clean up the do_unlink() call). Jeremy. --- source3/locking/locking.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'source3/locking') diff --git a/source3/locking/locking.c b/source3/locking/locking.c index 5a6fdf081e..26018f90db 100644 --- a/source3/locking/locking.c +++ b/source3/locking/locking.c @@ -1307,18 +1307,11 @@ bool downgrade_share_oplock(struct share_mode_lock *lck, files_struct *fsp) } /**************************************************************************** - Deal with the internal needs of setting the delete on close flag. Note that - as the tdb locking is recursive, it is safe to call this from within - open_file_ntcreate. JRA. + Check if setting delete on close is allowed on this fsp. ****************************************************************************/ -NTSTATUS can_set_delete_on_close(files_struct *fsp, bool delete_on_close, - uint32 dosmode) +NTSTATUS can_set_delete_on_close(files_struct *fsp, uint32 dosmode) { - if (!delete_on_close) { - return NT_STATUS_OK; - } - /* * Only allow delete on close for writable files. */ -- cgit