From: Jeremy Allison Date: Thu, 11 Mar 2021 21:42:31 +0000 (-0800) Subject: s3: smbd: Change SMB_VFS_REMOVEXATTR -> SMB_VFS_FREMOVEXATTR. X-Git-Tag: tevent-0.11.0~1279 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=4f977b61e906d0b9f68daa646cb0ff656a3768d2;p=thirdparty%2Fsamba.git s3: smbd: Change SMB_VFS_REMOVEXATTR -> SMB_VFS_FREMOVEXATTR. We no longer need pathname based xattr remove. Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index 3adb59e3b46..8449f745ff5 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -792,20 +792,10 @@ NTSTATUS set_ea(connection_struct *conn, files_struct *fsp, if (ea_list->ea.value.length == 0) { /* Remove the attribute. */ - if (!fsp->fsp_flags.is_pathref && - fsp_get_io_fd(fsp) != -1) - { - DEBUG(10,("set_ea: deleting ea name %s on " - "file %s by file descriptor.\n", - unix_ea_name, fsp_str_dbg(fsp))); - ret = SMB_VFS_FREMOVEXATTR(fsp, unix_ea_name); - } else { - DEBUG(10,("set_ea: deleting ea name %s on file %s.\n", - unix_ea_name, fsp->fsp_name->base_name)); - ret = SMB_VFS_REMOVEXATTR(conn, - fsp->fsp_name, - unix_ea_name); - } + DBG_DEBUG("deleting ea name %s on " + "file %s by file descriptor.\n", + unix_ea_name, fsp_str_dbg(fsp)); + ret = SMB_VFS_FREMOVEXATTR(fsp, unix_ea_name); #ifdef ENOATTR /* Removing a non existent attribute always succeeds. */ if (ret == -1 && errno == ENOATTR) {