]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Got rid of startup functions and filters_postconfig().
authorMartin Mares <mj@ucw.cz>
Mon, 15 May 2000 10:53:56 +0000 (10:53 +0000)
committerMartin Mares <mj@ucw.cz>
Mon, 15 May 2000 10:53:56 +0000 (10:53 +0000)
By the way, how do you expect pointers to fit in an int?

TODO
conf/conf.c
filter/config.Y
filter/filter.c
filter/filter.h

diff --git a/TODO b/TODO
index 9581a482536c98afa06e1187f84001a9d3e9d040..d80b7cb8bfb5c7593932c92549c26e2b6dbe9b55 100644 (file)
--- a/TODO
+++ b/TODO
@@ -9,6 +9,8 @@ Core
 - filters: deletion of mandatory attributes?
 - filters: user defined attributes?
 
+- kernel: persistent mode
+
 - cli: show tables?
 
 - client: Ctrl-R eats one more enter
@@ -32,9 +34,6 @@ Documentation
 Globals
 ~~~~~~~
 - right usage of DBG vs. debug
-- kill preconfigs?
-- check dump functions
-- cleanup debugging calls
 - logging and tracing; use appropriate log levels
 - check incoming packets and log errors!!
 - check log calls for trailing newlines and log levels followed by comma
index 323655d30eba803f6b291e4b67dbb9a4bda5a5c4..dd71642424a9f21c75f6e664b4e4b921a2c597f3 100644 (file)
@@ -58,7 +58,6 @@ config_parse(struct config *c)
   protos_preconfig(c);
   rt_preconfig(c);
   cf_parse();
-  filters_postconfig();                        /* FIXME: Do we really need this? */
   protos_postconfig(c);
 #ifdef IPV6
   if (!c->router_id)
index 4c4a859a72a8e3103db87ad5d952bd4abdc9b2cd..8988241b67d35f892783a543607bc91522d38612 100644 (file)
@@ -170,14 +170,7 @@ function_body:
 CF_ADDTO(conf, function_def)
 function_def:
    FUNCTION SYM { DBG( "Beginning of function %s\n", $2->name ); cf_push_scope($2); } function_params function_body {
-     extern struct f_inst *startup_func, *test1_func, *test2_func;
      cf_define_symbol($2, SYM_FUNCTION, $5);
-     if (!strcasecmp($2->name, "__startup"))
-       startup_func = $5;
-     if (!strcasecmp($2->name, "__test1"))
-       test1_func = $5;
-     if (!strcasecmp($2->name, "__test2"))
-       test2_func = $5;
      $2->aux = (int) $4;
      $2->aux2 = $5;
      DBG("Hmm, we've got one function here - %s\n", $2->name); 
index 2510b6a3e9ae7013f613a2063cc44ad65cad58b1..c9350c9651503408ebf78495afe59b73b75394ce 100644 (file)
@@ -43,8 +43,6 @@
 
 #define P(a,b) ((a<<8) | b)
 
-struct f_inst *startup_func = NULL, *test1_func, *test2_func;
-
 #define CMP_ERROR 999
 
 static int
@@ -682,25 +680,6 @@ f_eval_int(struct f_inst *expr)
   return res.val.i;
 }
 
-void
-filters_postconfig(void)
-{
-  struct f_val res;
-
-#if 1
-  if (!i_same(test1_func, test2_func))
-    bug("i_same does not work");
-#endif
-  if (startup_func) {
-    debug( "Launching startup function...\n" );
-    f_pool = lp_new(&root_pool, 1024);
-    res = interpret(startup_func);
-    if (res.type == F_ERROR)
-      die( "Startup function resulted in error." );
-    debug( "done\n" );
-  }
-} 
-
 /**
  * filter_same - compare two filters
  * @new: first filter to be compared
index b746063ee4b48b48148dbb17f8613d12d8cf0ccd..3a62cd7e30f802bc68d49f81738f2beb068922dc 100644 (file)
@@ -58,7 +58,6 @@ struct filter {
   struct f_inst *root;
 };
 
-void filters_postconfig(void);
 struct f_inst *f_new_inst(void);
 struct f_inst *f_new_dynamic_attr(int type, int f_type, int code);     /* Type as core knows it, type as filters know it, and code of dynamic attribute */
 struct f_tree *f_new_tree(void);