diff options
-rw-r--r-- | source3/locking/locking.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/source3/locking/locking.c b/source3/locking/locking.c index 62304076af..fa56e0a628 100644 --- a/source3/locking/locking.c +++ b/source3/locking/locking.c @@ -109,8 +109,11 @@ int fd_close_posix(struct connection_struct *conn, files_struct *fsp) int ret; size_t i; - if (!lp_posix_locking(SNUM(conn))) - return True; + if (!lp_posix_locking(SNUM(conn))) { + ret = conn->vfs_ops.close(fsp->fd); + fsp->fd = -1; + return ret; + } pc = find_pending_close_entry(fsp->dev, fsp->inode); |