From: Jeremy Allison Date: Fri, 4 Oct 2019 22:16:06 +0000 (-0700) Subject: s3: VFS: vfs_posix_eadb: Convert streams_depot_rmdir_internal() to call UNLINKAT... X-Git-Tag: talloc-2.3.1~424 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=881ee37c81c0b94c62c92cd4debf2fe52ad7cd63;p=thirdparty%2Fsamba.git s3: VFS: vfs_posix_eadb: Convert streams_depot_rmdir_internal() to call UNLINKAT() instead of RMDIR(). Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- diff --git a/source3/modules/vfs_streams_depot.c b/source3/modules/vfs_streams_depot.c index e0cfac2d990..5be72fc1835 100644 --- a/source3/modules/vfs_streams_depot.c +++ b/source3/modules/vfs_streams_depot.c @@ -796,13 +796,19 @@ static int streams_depot_rmdir(vfs_handle_struct *handle, errno = ENOMEM; return -1; } - SMB_VFS_NEXT_RMDIR(handle, smb_fname_dir); + SMB_VFS_NEXT_UNLINKAT(handle, + dirfsp, + smb_fname_dir, + AT_REMOVEDIR); TALLOC_FREE(smb_fname_dir); } TALLOC_FREE(dirname); } - ret = SMB_VFS_NEXT_RMDIR(handle, smb_fname_base); + ret = SMB_VFS_NEXT_UNLINKAT(handle, + dirfsp, + smb_fname_base, + AT_REMOVEDIR); TALLOC_FREE(smb_fname_base); return ret; }