r21664: Fix #4425 - patch from Jason Mader <jason@ncac.gwu.edu>.
authorJeremy Allison <jra@samba.org>
Fri, 2 Mar 2007 20:56:18 +0000 (20:56 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 17:18:22 +0000 (12:18 -0500)
Jeremy
(This used to be commit 24a4d4d7adefc4590f7e38cc72f54dc692cf9856)

source3/modules/vfs_default.c

index bd7bea5258a405e1e446dc90c97f116702ebd5f9..c0b80e17754a61d9f93203b883d54c4dc9170101 100644 (file)
@@ -786,7 +786,7 @@ static BOOL vfswrap_getlock(vfs_handle_struct *handle, files_struct *fsp, int fd
 static int vfswrap_linux_setlease(vfs_handle_struct *handle, files_struct *fsp, int fd,
                                int leasetype)
 {
-       int result;
+       int result = -1;
 
        START_PROFILE(syscall_linux_setlease);
 
@@ -796,7 +796,8 @@ static int vfswrap_linux_setlease(vfs_handle_struct *handle, files_struct *fsp,
                return -1;
 
        result = linux_setlease(fd, leasetype);
-       
+#else
+       errno = ENOSYS;
 #endif
        END_PROFILE(syscall_linux_setlease);
        return result;