]> git.puffer.fish Git - mirror/frr.git/commitdiff
Fix critical bugzilla #113. Make CMD_ERR_NOTHING_TODO nonfatal.
authorhasso <hasso>
Wed, 13 Oct 2004 08:18:07 +0000 (08:18 +0000)
committerhasso <hasso>
Wed, 13 Oct 2004 08:18:07 +0000 (08:18 +0000)
lib/ChangeLog
lib/command.c

index 1e6f51ca49f0bc095b0bc22062060a487573bf95..25f48dd763e99ca7b73e1f81a2a7fbc8a4ceb3ba 100644 (file)
@@ -1,3 +1,8 @@
+2004-10-13 Hasso Tepper <hasso at quagga.net>
+
+       * command.c: Make CMD_ERR_NOTHING_TODO nonfatal if reading
+         configuration from file. Fixes critical bugzilla #113.
+
 2004-10-13 Paul Jakma <paul@dishone.st>
 
        * (global) more const'ification.
index 0e61e0d8d1ae414d0767e10201b5bf131e8953c8..4495d2213c68e186d507a78347c12cfe988ccf00 100644 (file)
@@ -2238,15 +2238,16 @@ config_from_file (struct vty *vty, FILE *fp)
 
       /* Try again with setting node to CONFIG_NODE */
       while (ret != CMD_SUCCESS && ret != CMD_WARNING
-            && vty->node != CONFIG_NODE)
-               {
+            && ret != CMD_ERR_NOTHING_TODO && vty->node != CONFIG_NODE)
+       {
          vty->node = node_parent(vty->node);
-                 ret = cmd_execute_command_strict (vline, vty, NULL);
-               }
+         ret = cmd_execute_command_strict (vline, vty, NULL);
+       }
 
       cmd_free_strvec (vline);
 
-      if (ret != CMD_SUCCESS && ret != CMD_WARNING)
+      if (ret != CMD_SUCCESS && ret != CMD_WARNING
+         && ret != CMD_ERR_NOTHING_TODO)
        return ret;
     }
   return CMD_SUCCESS;