summaryrefslogtreecommitdiff
path: root/source3/locking
diff options
context:
space:
mode:
authorSimo Sorce <idra@samba.org>2010-04-28 19:42:04 -0400
committerJeremy Allison <jra@samba.org>2010-04-30 11:52:39 -0700
commitdffeb12f3dcb339bc258a7fbc38bbf9ec8dd928e (patch)
treeb9e26e4bd2aad5f419ac42e4979f7c85d884a8e0 /source3/locking
parentb9a97cf8649141dcd13f09cd1866d60f090d0bbe (diff)
downloadsamba-dffeb12f3dcb339bc258a7fbc38bbf9ec8dd928e.tar.gz
samba-dffeb12f3dcb339bc258a7fbc38bbf9ec8dd928e.tar.bz2
samba-dffeb12f3dcb339bc258a7fbc38bbf9ec8dd928e.zip
smbd: move printfile_offset() within write_file()
Diffstat (limited to 'source3/locking')
-rw-r--r--source3/locking/locking.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source3/locking/locking.c b/source3/locking/locking.c
index a2581b1b96..3975a78673 100644
--- a/source3/locking/locking.c
+++ b/source3/locking/locking.c
@@ -241,6 +241,12 @@ struct byte_range_lock *do_lock(struct messaging_context *msg_ctx,
{
struct byte_range_lock *br_lck = NULL;
+ /* silently return ok on print files as we don't do locking there */
+ if (fsp->print_file) {
+ *perr = NT_STATUS_OK;
+ return NULL;
+ }
+
if (!fsp->can_lock) {
*perr = fsp->is_directory ? NT_STATUS_INVALID_DEVICE_REQUEST : NT_STATUS_INVALID_HANDLE;
return NULL;