diff options
author | Jeremy Allison <jra@samba.org> | 2009-11-30 15:53:04 -0800 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2009-11-30 15:53:04 -0800 |
commit | 8303bc49a45d5bab0cdbd4f2d793088f600f715f (patch) | |
tree | de386a449efb20c1cbb4fc3a62a6e6bb588d4810 /source3/modules/vfs_recycle.c | |
parent | b852a3494aa3af3d69175f68669609b23fefc1bb (diff) | |
download | samba-8303bc49a45d5bab0cdbd4f2d793088f600f715f.tar.gz samba-8303bc49a45d5bab0cdbd4f2d793088f600f715f.tar.bz2 samba-8303bc49a45d5bab0cdbd4f2d793088f600f715f.zip |
Restructure the connect function code to always call
down to NEXT-> before initializing. This allows us to
do cleanup (by calling DISCONNECT) if initialization
fails. Also fix vfs_acl_xattr which was failing to
call the NEXT connect function.
Jeremy.
Diffstat (limited to 'source3/modules/vfs_recycle.c')
-rw-r--r-- | source3/modules/vfs_recycle.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/source3/modules/vfs_recycle.c b/source3/modules/vfs_recycle.c index 0c019dbd70..667442732e 100644 --- a/source3/modules/vfs_recycle.c +++ b/source3/modules/vfs_recycle.c @@ -38,10 +38,16 @@ static int recycle_unlink(vfs_handle_struct *handle, static int recycle_connect(vfs_handle_struct *handle, const char *service, const char *user) { + int ret = SMB_VFS_NEXT_CONNECT(handle, service, user); + + if (ret < 0) { + return ret; + } + DEBUG(10,("recycle_connect() connect to service[%s] as user[%s].\n", service,user)); - return SMB_VFS_NEXT_CONNECT(handle, service, user); + return 0; } static void recycle_disconnect(vfs_handle_struct *handle) |