r22094: Clarify that SMB_VFS_LOCK should not be used to get lock status.
authorJames Peach <jpeach@samba.org>
Thu, 5 Apr 2007 19:49:29 +0000 (19:49 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 17:19:10 +0000 (12:19 -0500)
source/modules/vfs_default.c

index 98e9aaa2631754a6bb9f6c8e7b3cab41de7e169a..6410e7aad5f320246dc702ba532f54f54a85cbe9 100644 (file)
@@ -781,6 +781,9 @@ static BOOL vfswrap_lock(vfs_handle_struct *handle, files_struct *fsp, int fd, i
 {
        BOOL result;
 
+       /* SMB_VFS_GETLOCK should be used to query lock status. */
+       SMB_ASSERT(op != SMB_F_GETLK);
+
        START_PROFILE(syscall_fcntl_lock);
        result =  fcntl_lock(fd, op, offset, count, type);
        END_PROFILE(syscall_fcntl_lock);