]> git.puffer.fish Git - mirror/frr.git/commitdiff
[ospfd] Fix ospf passive-interface subcommand to create interface if necessary
authorAndrew J. Schorr <ajschorr@alumni.princeton.edu>
Sun, 18 Jun 2006 00:45:48 +0000 (00:45 +0000)
committerAndrew J. Schorr <ajschorr@alumni.princeton.edu>
Sun, 18 Jun 2006 00:45:48 +0000 (00:45 +0000)
2006-06-17 Andrew J. Schorr <ajschorr@alumni.princeton.edu>

* ospf_vty.c: ({no_,}ospf_passive_interface) Replace if_lookup_by_name
  with a call to if_get_by_name -- if the interface does not exist
  already, it should be created.  And remove the obsolete warning
  message.

ospfd/ChangeLog
ospfd/ospf_vty.c

index b7f2c95f5b59db308755cd5ce85384ee58daa012..779a2b6147648bf5971f5f602df8e56ee2e17f18 100644 (file)
@@ -1,3 +1,10 @@
+2006-06-17 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
+
+       * ospf_vty.c: ({no_,}ospf_passive_interface) Replace if_lookup_by_name
+         with a call to if_get_by_name -- if the interface does not exist
+         already, it should be created.  And remove the obsolete warning
+         message.
+
 2006-06-15 Paul Jakma <paul.jakma@sun.com>
 
        * ospf_interface.h: (struct ospf_if_info) Add reference counts
index 10580ab7ca19e546d6d1a663bcef9e41cf04356d..7c367ea2dae6daf7dd55624d71ce6acb4ae59668 100644 (file)
@@ -261,13 +261,7 @@ DEFUN (ospf_passive_interface,
  struct ospf_if_params *params;
  struct route_node *rn;
 
- ifp = if_lookup_by_name (argv[0]);
- if (ifp == NULL)
-   {
-     vty_out (vty, "Please specify an existing interface%s", VTY_NEWLINE);
-     return CMD_WARNING;
-   }
+ ifp = if_get_by_name (argv[0]);
 
   params = IF_DEF_PARAMS (ifp);
 
@@ -331,13 +325,7 @@ DEFUN (no_ospf_passive_interface,
   int ret;
   struct route_node *rn;
     
-  ifp = if_lookup_by_name (argv[0]);
-  
-  if (ifp == NULL)
-    {
-      vty_out (vty, "Please specify an existing interface%s", VTY_NEWLINE);
-      return CMD_WARNING;
-    }
+  ifp = if_get_by_name (argv[0]);
 
   params = IF_DEF_PARAMS (ifp);