diff --git a/source3/modules/vfs_fruit.c b/source3/modules/vfs_fruit.c index d6430f82f63..6c391a1d244 100644 --- a/source3/modules/vfs_fruit.c +++ b/source3/modules/vfs_fruit.c @@ -3122,9 +3122,9 @@ static int fruit_stat_base(vfs_handle_struct *handle, return rc; } -static int fruit_stat_meta(vfs_handle_struct *handle, - struct smb_filename *smb_fname, - bool follow_links) +static int fruit_stat_meta_netatalk(vfs_handle_struct *handle, + struct smb_filename *smb_fname, + bool follow_links) { struct adouble *ad = NULL; @@ -3147,6 +3147,30 @@ static int fruit_stat_meta(vfs_handle_struct *handle, return 0; } +static int fruit_stat_meta(vfs_handle_struct *handle, + struct smb_filename *smb_fname, + bool follow_links) +{ + struct fruit_config_data *config = NULL; + int ret; + + SMB_VFS_HANDLE_GET_DATA(handle, config, + struct fruit_config_data, return -1); + + switch (config->meta) { + case FRUIT_META_STREAM: + case FRUIT_META_NETATALK: + ret = fruit_stat_meta_netatalk(handle, smb_fname, follow_links); + break; + + default: + DBG_ERR("Unexpected meta config [%d]\n", config->meta); + return -1; + } + + return ret; +} + static int fruit_stat_rsrc(vfs_handle_struct *handle, struct smb_filename *smb_fname, bool follow_links)