summaryrefslogtreecommitdiffstats
path: root/source/smbd/filename.c
diff options
context:
space:
mode:
Diffstat (limited to 'source/smbd/filename.c')
-rw-r--r--source/smbd/filename.c19
1 files changed, 12 insertions, 7 deletions
diff --git a/source/smbd/filename.c b/source/smbd/filename.c
index eb86a0efd16..570297bf69f 100644
--- a/source/smbd/filename.c
+++ b/source/smbd/filename.c
@@ -392,20 +392,25 @@ NTSTATUS unix_convert(connection_struct *conn,
* these two errors.
*/
- /* ENOENT and ENOTDIR both map to NT_STATUS_OBJECT_PATH_NOT_FOUND
- in the filename walk. */
+ /* ENOENT, ENOTDIR and ELOOP all map to
+ * NT_STATUS_OBJECT_PATH_NOT_FOUND
+ * in the filename walk. */
- if (errno == ENOENT || errno == ENOTDIR) {
+ if (errno == ENOENT ||
+ errno == ENOTDIR ||
+ errno == ELOOP) {
return NT_STATUS_OBJECT_PATH_NOT_FOUND;
}
return map_nt_error_from_unix(errno);
}
-
+
/* ENOENT is the only valid error here. */
if (errno != ENOENT) {
- /* ENOENT and ENOTDIR both map to NT_STATUS_OBJECT_PATH_NOT_FOUND
- in the filename walk. */
- if (errno == ENOTDIR) {
+ /* ENOTDIR and ELOOP both map to
+ * NT_STATUS_OBJECT_PATH_NOT_FOUND
+ * in the filename walk. */
+ if (errno == ENOTDIR ||
+ errno == ELOOP) {
return NT_STATUS_OBJECT_PATH_NOT_FOUND;
}
return map_nt_error_from_unix(errno);