Windows: Symlink resolve failure error
authorJeffrey Altman <jaltman@your-file-system.com>
Thu, 29 Dec 2011 17:42:26 +0000 (12:42 -0500)
committerJeffrey Altman <jaltman@secure-endpoints.com>
Sat, 31 Dec 2011 21:17:28 +0000 (13:17 -0800)
If a symlink cannot be resolved, return STATUS_REPARSE_POINT_NOT_RESOLVED
instead of STATUS_ACCESS_DENIED.  The symlink is after all a reparse
point.  This results in a more meaningful error being delivered to
the end user.

Change-Id: I30713dac7b916efaf3cf7a5d7717cb0bc971a31a
Reviewed-on: http://gerrit.openafs.org/6441
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com>

src/WINNT/afsrdr/kernel/lib/AFSGeneric.cpp

index b2a5d23..8350076 100644 (file)
@@ -7998,10 +7998,10 @@ AFSCheckSymlinkAccess( IN AFSDirectoryCB *ParentDirectoryCB,
 
         AFSDbgLogMsg( AFS_SUBSYSTEM_FILE_PROCESSING,
                       AFS_TRACE_LEVEL_VERBOSE_2,
-                      "AFSCheckSymlinkAccess Failing symlink access to entry %wZ ACCESS_DENIED\n",
+                      "AFSCheckSymlinkAccess Failing symlink access to entry %wZ REPARSE_POINT_NOT_RESOLVED\n",
                       ComponentName);
 
-        ntStatus = STATUS_ACCESS_DENIED;
+        ntStatus = STATUS_REPARSE_POINT_NOT_RESOLVED;
 
         InterlockedDecrement( &pDirEntry->OpenReferenceCount);