Ticket #52: ndpsmb.diff

File ndpsmb.diff, 802 bytes (added by KO Myung-Hun, 17 years ago)

retry to launch smbcd when it crashed after accesing a file

  • ndpsmb/ndpsmb.c

     
    11831183        smb_response resp = {0};
    11841184        smbwrp_fileinfo * finfo = (smbwrp_fileinfo *)pConn->mem;
    11851185        char path[CCHMAXPATH+1] = {0};
     1186    int retry = 0;
    11861187
    1187         log("NdpQueryInfo in <%s>\n", szPath);
     1188do
     1189{
     1190    log("NdpQueryInfo in <%s>, retry = %d\n", szPath, retry);
    11881191
    11891192        do {
    11901193                if (ph->fsphStrChr(szPath, '*') || ph->fsphStrChr(szPath, '?'))
     
    12731276                        }
    12741277                }
    12751278        } while (0);
     1279    log("NdpQueryInfo <%s> (%s) %d %d\n", szPath, path, rc, pConn->rc);
    12761280
    1277         log("NdpQueryInfo <%s> (%s) %d %d\n", szPath, path, rc, pConn->rc);
     1281    retry = rc && !retry;
     1282} while( retry );
     1283
    12781284        return rc;
    12791285}
    12801286