Whamcloud - gitweb
b=2699
authorrread <rread>
Thu, 12 Feb 2004 01:28:08 +0000 (01:28 +0000)
committerrread <rread>
Thu, 12 Feb 2004 01:28:08 +0000 (01:28 +0000)
Make sure this request was replied before unpacking, and if not return
an error.

lustre/ptlrpc/client.c

index 12cf867..fdc1b37 100644 (file)
@@ -1489,6 +1489,11 @@ static int ptlrpc_replay_interpret(struct ptlrpc_request *req,
         unsigned long flags;
 
         atomic_dec(&imp->imp_replay_inflight);
+        
+        if (!req->rq_replied) {
+                CERROR("request replay timed out, restarting recovery\n");
+                GOTO(out, rc = -ETIMEDOUT);
+        }
 
 #if SWAB_PARANOIA
         /* Clear reply swab mask; this is a new reply in sender's byte order */