From 61b04b19ad4bf2c62ec4309efeba4f442a54d8f2 Mon Sep 17 00:00:00 2001 From: Jeffrey Altman Date: Mon, 24 Oct 2011 21:14:59 -0400 Subject: [PATCH] Windows: afsredir only wants shortName if not 8.3 When performing a directory enumeration for the afs redirector only specify a shortname if the name is not valid 8.3. Change-Id: I650be75b9ea8e41721272cd8bd426f1989ca01fb Reviewed-on: http://gerrit.openafs.org/5727 Tested-by: Jeffrey Altman Reviewed-by: Jeffrey Altman --- src/WINNT/afsrdr/user/RDRFunction.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/WINNT/afsrdr/user/RDRFunction.c b/src/WINNT/afsrdr/user/RDRFunction.c index eb71773796..ed232bcd41 100644 --- a/src/WINNT/afsrdr/user/RDRFunction.c +++ b/src/WINNT/afsrdr/user/RDRFunction.c @@ -861,7 +861,8 @@ RDR_EnumerateDirectory( IN cm_user_t *userp, if (scp) { code = RDR_PopulateCurrentEntry(pCurrentEntry, dwMaxEntryLength, dscp, scp, userp, &req, - entryp->name, entryp->shortName, + entryp->name, + cm_Is8Dot3(entryp->name) ? NULL : entryp->shortName, (bWow64 ? RDR_POP_WOW64 : 0) | (bSkipStatus ? RDR_POP_NO_GETSTATUS : 0), &pCurrentEntry, &dwMaxEntryLength); @@ -869,7 +870,8 @@ RDR_EnumerateDirectory( IN cm_user_t *userp, } else { code = RDR_PopulateCurrentEntryNoScp( pCurrentEntry, dwMaxEntryLength, dscp, &entryp->fid, userp, &req, - entryp->name, entryp->shortName, + entryp->name, + cm_Is8Dot3(entryp->name) ? NULL : entryp->shortName, (bWow64 ? RDR_POP_WOW64 : 0), &pCurrentEntry, &dwMaxEntryLength); } @@ -1385,6 +1387,7 @@ RDR_CreateFileEntry( IN cm_user_t *userp, cm_Gen8Dot3NameIntW(FileName, &dfid, shortName, NULL); else shortName[0] = '\0'; + code = RDR_PopulateCurrentEntry(&pResultCB->DirEnum, dwRemaining, dscp, scp, userp, &req, FileName, shortName, RDR_POP_FOLLOW_MOUNTPOINTS | RDR_POP_EVALUATE_SYMLINKS, @@ -2303,6 +2306,7 @@ RDR_RenameFileEntry( IN cm_user_t *userp, cm_Gen8Dot3NameIntW(TargetFileName, &dfid, shortName, NULL); else shortName[0] = '\0'; + RDR_PopulateCurrentEntry(&pResultCB->DirEnum, dwRemaining, newDscp, scp, userp, &req, TargetFileName, shortName, RDR_POP_FOLLOW_MOUNTPOINTS | RDR_POP_EVALUATE_SYMLINKS,