From c34c5822cd1629700e5da86b4a8b6cb879f071d8 Mon Sep 17 00:00:00 2001 From: Jeffrey Altman Date: Sat, 6 Mar 2004 13:27:48 +0000 Subject: [PATCH] corrections-to-MIT-merge-20040306 * Corrections to MIT merge caught by Asanka. --- src/WINNT/afsd/smb.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/WINNT/afsd/smb.c b/src/WINNT/afsd/smb.c index 95e772eb95..90bd9fbb31 100644 --- a/src/WINNT/afsd/smb.c +++ b/src/WINNT/afsd/smb.c @@ -1131,7 +1131,7 @@ int smb_ListShares() sbmtpath); if (!len) return num_shares; p = pathName; - if (strncmp(p, cm_mountRoot, 4) != 0) + if (strncmp(p, cm_mountRoot, strlen(cm_mountRoot)) != 0) print_afs = 1; while (*p) { if (*p == '\\') *p = '/'; /* change to / */ @@ -1216,7 +1216,7 @@ int smb_FindShare(smb_vc_t *vcp, smb_packet_t *inp, char *shareName, /* We can accept either unix or PC style AFS pathnames. Convert Unix-style to PC style here for internal use. */ p = pathName; - if (strncmp(p, cm_mountRoot, 4) == 0) + if (strncmp(p, cm_mountRoot, strlen(cm_mountRoot) == 0) p += strlen(cm_mountRoot); /* skip mount path */ q = p; while (*q) { @@ -2825,11 +2825,10 @@ long smb_ApplyDirListPatches(smb_dirListPatch_t **dirPatchespp, dptr = patchp->dptr; attr = smb_Attributes(scp); - *dptr++ = attr; - /* check hidden attribute (the flag is only ON when dot file hiding is on ) */ if( patchp->flags & SMB_DIRLISTPATCH_DOTFILE ) attr |= SMB_ATTR_HIDDEN; + *dptr++ = attr; /* get dos time */ smb_SearchTimeFromUnixTime(&dosTime, scp->clientModTime);