}
/****************************************************************************
- Check a filename - possibly caling reducename.
+ Check a filename - possibly calling check_reduced_name.
This is called by every routine before it allows an operation on a filename.
It does any final confirmation necessary to ensure that the filename is
a valid one for the user to access.
}
if (!lp_widelinks(SNUM(conn)) || !lp_symlinks(SNUM(conn))) {
- NTSTATUS status = reduce_name(conn,name);
+ NTSTATUS status = check_reduced_name(conn,name);
if (!NT_STATUS_IS_OK(status)) {
DEBUG(5,("check_name: name %s failed with %s\n",name, nt_errstr(status)));
return status;
}
/* Ensure this is within the share. */
- status = reduce_name(conn, oldname);
+ status = check_reduced_name(conn, oldname);
if (!NT_STATUS_IS_OK(status)) {
return status;
}
}
/* Ensure this is within the share. */
- status = reduce_name(conn, oldname);
+ status = check_reduced_name(conn, oldname);
if (!NT_STATUS_IS_OK(status)) {
return status;
}
it is below dir in the heirachy. This uses realpath.
********************************************************************/
-NTSTATUS reduce_name(connection_struct *conn, const pstring fname)
+NTSTATUS check_reduced_name(connection_struct *conn, const char *fname)
{
#ifdef REALPATH_TAKES_NULL
BOOL free_resolved_name = True;