• Ralph Boehme's avatar
    vfs_fruit: change trigger points of AppleDouble conversion · 8b1dfd9b
    Ralph Boehme authored
    This moves the trigger points where AppleDouble file conversion is run by
    ad_convert() from deep down the callchain in ad_read_rsrc_adouble() to high
    level VFS entry points.
    
    Currently ad_convert() will be triggered as part of open_file_ntcreate(...,
    "file:AFP_AfpResource", ...): after SMB_VFS_OPEN() has been called with O_CREAT,
    what created the file, we call SMB_VFS_FSTAT() on the just created
    filehandle. This ends up in ad_convert(), finds the resource fork empty and thus
    deletes the file.
    
    This commit moves calling of the conversion funtion to the high level VFS entry
    points where the converted metadata is needed:
    
    o for directory enumerations SMB_VFS_READDIR_ATTR() is called to fill in the
      repurposed fields in the directory entry metadata
    
    o obviously for SMB_VFS_CREATE_FILE() on an macOS stream
    
    Bug: https://bugzilla.samba.org/show_bug.cgi?id=13958Signed-off-by: 's avatarRalph Boehme <slow@samba.org>
    Reviewed-by: 's avatarJeremy Allison <jra@samba.org>
    (cherry picked from commit 78a4639b)
    
    Autobuild-User(v4-9-test): Karolin Seeger <kseeger@samba.org>
    Autobuild-Date(v4-9-test): Thu Jun 13 14:25:17 UTC 2019 on sn-devel-144
    8b1dfd9b
Name
Last commit
Last update
..
README Loading commit data...
dns Loading commit data...
encrypted_secrets Loading commit data...
getncchanges Loading commit data...
keytab Loading commit data...
labdc Loading commit data...
netlogon Loading commit data...
ntlmv1-restrictions Loading commit data...
ntlmv2-restrictions Loading commit data...
password_settings Loading commit data...
replica_sync Loading commit data...
s3-lsa-server Loading commit data...
samba3.vfs.fruit Loading commit data...
smbclient-smb3 Loading commit data...
upn_handling Loading commit data...