summaryrefslogtreecommitdiff
path: root/source3/modules/vfs_fruit.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2014-12-05 15:37:11 -0800
committerKarolin Seeger <kseeger@samba.org>2014-12-08 12:37:27 +0100
commit3e8a1681b613608e2c282a07b76387f9fbf549e0 (patch)
tree53b71ed9507bd19c5b5d9ab28bd949136110b91d /source3/modules/vfs_fruit.c
parent46489da33949b05866ed0bbedb3e18b0d95189ab (diff)
downloadsamba-3e8a1681b613608e2c282a07b76387f9fbf549e0.tar.gz
s3: modules: Fix *allocate* calls to follow POSIX error return convention.
Fix up the ceph, fruit, time_audit and streams_xattr modules to follow the -1,errno convention for errors. Reported by Jones <jones.kstw@gmail.com> who provided the initial patch. This patch tested and confirmed working by him as well. Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: David Disseldorp <ddiss@suse.de> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Mon Dec 8 02:59:43 CET 2014 on sn-devel-104 (cherry picked from commit 2845e1c29f8bce6306a73d546184c401bf89cfea) Autobuild-User(v4-2-test): Karolin Seeger <kseeger@samba.org> Autobuild-Date(v4-2-test): Mon Dec 8 12:37:27 CET 2014 on sn-devel-104
Diffstat (limited to 'source3/modules/vfs_fruit.c')
-rw-r--r--source3/modules/vfs_fruit.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source3/modules/vfs_fruit.c b/source3/modules/vfs_fruit.c
index c5d92ef5c99..23a7f16d58f 100644
--- a/source3/modules/vfs_fruit.c
+++ b/source3/modules/vfs_fruit.c
@@ -3049,11 +3049,12 @@ static int fruit_fallocate(struct vfs_handle_struct *handle,
}
if (!fruit_fsp_recheck(ad, fsp)) {
- return errno;
+ return -1;
}
/* Let the pwrite code path handle it. */
- return ENOSYS;
+ errno = ENOSYS;
+ return -1;
}
static int fruit_ftruncate(struct vfs_handle_struct *handle,