if the guid2lid is corrupted, don't exit when running with -y option
authoreitan <eitan@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Tue, 23 May 2006 10:07:09 +0000 (10:07 +0000)
committereitan <eitan@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Tue, 23 May 2006 10:07:09 +0000 (10:07 +0000)
 (don't exit on fatal) - just ignore the file

git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@361 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

ulp/opensm/user/opensm/osm_lid_mgr.c

index 282b1c0..cd06c04 100644 (file)
@@ -301,12 +301,21 @@ osm_lid_mgr_init(
   {
     if (osm_db_restore(p_mgr->p_g2l))
     {
-      osm_log( p_mgr->p_log, OSM_LOG_ERROR,
-               "osm_lid_mgr_init: ERR 0317: "
-               "Error restoring Guid-to-Lid persistent database\n");
-      status = IB_ERROR;
-      goto Exit;
-    }
+        if (p_subn->opt.exit_on_fatal) 
+        {
+           osm_log( p_mgr->p_log, OSM_LOG_SYS,
+                   "Fatal: Error restoring Guid-to-Lid persistent
+                    database\n" );
+          status = IB_ERROR;
+          goto Exit;
+        }
+        else
+        {
+           osm_log( p_mgr->p_log, OSM_LOG_ERROR,
+                 "osm_lid_mgr_init: ERR 0317: "
+                 "Error restoring Guid-to-Lid persistent database\n");
+        }
+    } 
 
     /* we need to make sure we did not get duplicates with
        current lmc */