]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Preconfig, postconfig and init hooks can be NULL.
authorMartin Mares <mj@ucw.cz>
Sun, 18 Oct 1998 12:26:02 +0000 (12:26 +0000)
committerMartin Mares <mj@ucw.cz>
Sun, 18 Oct 1998 12:26:02 +0000 (12:26 +0000)
nest/proto.c

index 6c0843d888ae86b068e552f4742f23132e2d7c9a..f142a77dc945db093194f53e429051b0ccac788e 100644 (file)
@@ -48,7 +48,8 @@ protos_preconfig(void)
   WALK_LIST(p, protocol_list)
     {
       debug("...%s\n", p->name);
-      p->preconfig(p);
+      if (p->preconfig)
+       p->preconfig(p);
     }
 }
 
@@ -61,7 +62,8 @@ protos_postconfig(void)
   WALK_LIST(p, protocol_list)
     {
       debug("...%s\n", p->name);
-      p->postconfig(p);
+      if (p->postconfig)
+       p->postconfig(p);
     }
 }
 
@@ -121,5 +123,6 @@ protos_init(void)
 
   debug("Initializing protocols\n");
   WALK_LIST(p, protocol_list)
-    p->init(p);
+    if (p->init)
+      p->init(p);
 }