size_t num_names = 0;
/* Do we have any EA's ? */
status = get_ea_names_from_file(
- ctx, conn, fsp, smb_fname, NULL, &num_names);
+ ctx, conn, smb_fname->fsp, NULL, &num_names);
if (NT_STATUS_IS_OK(status) && num_names) {
file_status &= ~NO_EAS;
}
size_t num_names = 0;
/* Do we have any EA's ? */
status = get_ea_names_from_file(
- ctx, conn, fsp, smb_fname, NULL, &num_names);
+ ctx, conn, smb_fname->fsp, NULL, &num_names);
if (NT_STATUS_IS_OK(status) && num_names) {
file_status &= ~NO_EAS;
}
NTSTATUS get_ea_names_from_file(TALLOC_CTX *mem_ctx,
connection_struct *conn,
files_struct *fsp,
- const struct smb_filename *smb_fname,
char ***pnames,
size_t *pnum_names);
NTSTATUS set_ea(connection_struct *conn, files_struct *fsp,
NTSTATUS get_ea_names_from_file(TALLOC_CTX *mem_ctx,
connection_struct *conn,
files_struct *fsp,
- const struct smb_filename *smb_fname,
char ***pnames,
size_t *pnum_names)
{
}
*pnum_names = 0;
- status = refuse_symlink(conn, fsp, smb_fname);
- if (!NT_STATUS_IS_OK(status)) {
+ if (fsp == NULL) {
/*
- * Just return no EA's on a symlink.
+ * Callers may pass fsp == NULL when passing smb_fname->fsp of a
+ * symlink. This is ok, handle it here, by just return no EA's
+ * on a symlink.
*/
return NT_STATUS_OK;
}
status = get_ea_names_from_file(talloc_tos(),
conn,
fsp,
- smb_fname,
&names,
&num_names);