Whamcloud - gitweb
b=617434
authorpschwan <pschwan>
Thu, 3 Oct 2002 02:34:05 +0000 (02:34 +0000)
committerpschwan <pschwan>
Thu, 3 Oct 2002 02:34:05 +0000 (02:34 +0000)
Add some bulletproofing to sync_io_timeout, to try to fix this.

lustre/obdclass/genops.c

index 57e37e8..c843d68 100644 (file)
@@ -29,9 +29,15 @@ kmem_cache_t *import_cachep = NULL;
 static int sync_io_timeout(void *data)
 {
         struct io_cb_data *cbd = data;
-        struct ptlrpc_bulk_desc *desc = cbd->desc;
-
+        struct ptlrpc_bulk_desc *desc;
         ENTRY;
+
+        LASSERT(cbd);
+        desc = cbd->desc;
+
+        LASSERT(desc);
+        LASSERT(desc->bd_connection);
+
         desc->bd_connection->c_level = LUSTRE_CONN_RECOVD;
         desc->bd_flags |= PTL_RPC_FL_TIMEOUT;
         if (desc->bd_connection && class_signal_connection_failure) {