windows-no-more-files-workaround-20020725

work around erroneous "no more files" error in winnt client
This commit is contained in:
Ryan Lantzer 2002-07-26 06:09:56 +00:00 committed by Derrick Brashear
parent fd2cb884e2
commit 595f9ae433
2 changed files with 8 additions and 1 deletions

View File

@ -9,6 +9,8 @@
//#define NOSERVICE 1
#define NOMOREFILESFIX 1
#include <afs/param.h>
#include <afs/stds.h>
@ -2276,6 +2278,7 @@ long smb_ReceiveNegotiate(smb_vc_t *vcp, smb_packet_t *inp, smb_packet_t *outp)
namep += entryLength;
tcounter++; /* which proto entry we're looking at */
}
#ifndef NOMOREFILESFIX
/*
* NOTE: We can determine what OS (NT4.0, W2K, W9X, etc)
* the client is running by reading the protocol signature.
@ -2310,6 +2313,8 @@ long smb_ReceiveNegotiate(smb_vc_t *vcp, smb_packet_t *inp, smb_packet_t *outp)
*/
}
}
// NOMOREFILESFIX
#endif
if (NTProtoIndex != -1) {
protoIndex = NTProtoIndex;

View File

@ -1148,7 +1148,9 @@ long smb_ReceiveTran2QPathInfo(smb_vc_t *vcp, smb_tran2Packet_t *p, smb_packet_t
spacep = cm_GetSpace();
smb_StripLastComponent(spacep->data, &lastComp,
(char *)(&p->parmsp[3]));
if (strcmp(lastComp, "\\desktop.ini") == 0) {
/* Make sure that lastComp is not NULL */
if (lastComp)
if (strcmp(lastComp, "\\desktop.ini") == 0) {
code = cm_NameI(cm_rootSCachep, spacep->data,
CM_FLAG_CASEFOLD
| CM_FLAG_DIRSEARCH