• 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 78a4639b2d06cc69788861618d2e91945e142d2b)
    
    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
..
flapping.d Loading commit data...
gnupg Loading commit data...
knownfail.d Loading commit data...
manage-ca Loading commit data...
target Loading commit data...
README Loading commit data...
SocketWrapper.pm Loading commit data...
Subunit.pm Loading commit data...
TODO Loading commit data...
devel_env.sh Loading commit data...
filter-subunit Loading commit data...
flapping Loading commit data...
format-subunit Loading commit data...
format-subunit-json Loading commit data...
gdb_backtrace Loading commit data...
gdb_backtrace_test.c Loading commit data...
gdb_run Loading commit data...
in_screen Loading commit data...
knownfail Loading commit data...
perf_tests.py Loading commit data...
quick Loading commit data...
save.env.sh Loading commit data...
selftest.pl Loading commit data...
selftest.pl.1 Loading commit data...
selftesthelpers.py Loading commit data...
skip Loading commit data...
skip.no-GSS_KRB5_CRED_NO_CI_FLAGS_X Loading commit data...
skip_mit_kdc Loading commit data...
slow Loading commit data...
subunithelper.py Loading commit data...
tap2subunit Loading commit data...
tests.py Loading commit data...
valgrind_run Loading commit data...
wscript Loading commit data...