Windows: handle CM_ERROR_RETRY in cm_Analyze()
authorJeffrey Altman <jaltman@your-file-system.com>
Tue, 6 Nov 2012 11:41:47 +0000 (06:41 -0500)
committerJeffrey Altman <jaltman@your-file-system.com>
Thu, 31 Jan 2013 19:30:03 +0000 (11:30 -0800)
cm_Analyze() was not forcing a retry when it received CM_ERROR_RETRY.

Change-Id: I5c392623a3917bebdd5cb9bd86b030395d7a7d48
Reviewed-on: http://gerrit.openafs.org/8949
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Tested-by: Jeffrey Altman <jaltman@your-file-system.com>

src/WINNT/afsd/cm_conn.c

index 2ccbe42..c2aa8b2 100644 (file)
@@ -391,6 +391,7 @@ cm_Analyze(cm_conn_t *connp,
     }
 
     if (errorCode == CM_ERROR_TIMEDOUT) {
+       osi_Log0(afsd_logp, "cm_Analyze passed CM_ERROR_TIMEDOUT");
         if ( timeLeft > 5 ) {
             thrd_Sleep(3000);
             cm_CheckServers(CM_FLAG_CHECKDOWNSERVERS, cellp);
@@ -398,6 +399,11 @@ cm_Analyze(cm_conn_t *connp,
         }
     }
 
+    else if (errorCode == CM_ERROR_RETRY) {
+       osi_Log0(afsd_logp, "cm_Analyze passed CM_ERROR_RETRY");
+        retry = 1;
+    }
+
     else if (errorCode == UAEWOULDBLOCK || errorCode == EWOULDBLOCK ||
               errorCode == UAEAGAIN || errorCode == EAGAIN) {
        osi_Log0(afsd_logp, "cm_Analyze passed EWOULDBLOCK or EAGAIN.");
@@ -1261,8 +1267,6 @@ cm_Analyze(cm_conn_t *connp,
             case VL_BADMASK        : s = "VL_BADMASK";         break;
            case CM_ERROR_NOSUCHCELL        : s = "CM_ERROR_NOSUCHCELL";         break;
            case CM_ERROR_NOSUCHVOLUME      : s = "CM_ERROR_NOSUCHVOLUME";       break;
-           case CM_ERROR_TIMEDOUT          : s = "CM_ERROR_TIMEDOUT";           break;
-           case CM_ERROR_RETRY             : s = "CM_ERROR_RETRY";              break;
            case CM_ERROR_NOACCESS          : s = "CM_ERROR_NOACCESS";           break;
            case CM_ERROR_NOSUCHFILE        : s = "CM_ERROR_NOSUCHFILE";         break;
            case CM_ERROR_STOPNOW           : s = "CM_ERROR_STOPNOW";            break;