1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-01 05:47:28 +03:00

vfs_fruit: pass handle to ad_convert_delete_adfile()

On the course of removing ad_handle from struct adouble, step 10.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=13968

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
(cherry picked from commit 5f4d16b40e07acf8d27fee62f1a56de175663a1d)
This commit is contained in:
Ralph Boehme 2019-05-17 12:17:28 +02:00 committed by Karolin Seeger
parent fbc0501bed
commit 20e66673c3

View File

@ -1411,7 +1411,8 @@ static bool ad_convert_blank_rfork(vfs_handle_struct *handle,
return true;
}
static bool ad_convert_delete_adfile(struct adouble *ad,
static bool ad_convert_delete_adfile(vfs_handle_struct *handle,
struct adouble *ad,
const struct smb_filename *smb_fname)
{
struct fruit_config_data *config = NULL;
@ -1422,7 +1423,7 @@ static bool ad_convert_delete_adfile(struct adouble *ad,
return true;
}
SMB_VFS_HANDLE_GET_DATA(ad->ad_handle, config,
SMB_VFS_HANDLE_GET_DATA(handle, config,
struct fruit_config_data, return false);
if (!config->delete_empty_adfiles) {
@ -1434,7 +1435,7 @@ static bool ad_convert_delete_adfile(struct adouble *ad,
return false;
}
rc = SMB_VFS_NEXT_UNLINK(ad->ad_handle, ad_name);
rc = SMB_VFS_NEXT_UNLINK(handle, ad_name);
if (rc != 0) {
DBG_ERR("Unlinking [%s] failed: %s\n",
smb_fname_str_dbg(ad_name), strerror(errno));
@ -1499,7 +1500,7 @@ static int ad_convert(struct vfs_handle_struct *handle,
goto done;
}
ok = ad_convert_delete_adfile(ad, smb_fname);
ok = ad_convert_delete_adfile(handle, ad, smb_fname);
if (!ok) {
ret = -1;
goto done;