added GETD__ROUTINGTABLE and GETD__HNA_ROUTES to the plugin IO
authorAndreas Tonnesen <andreto@olsr.org>
Wed, 10 Nov 2004 16:58:46 +0000 (16:58 +0000)
committerAndreas Tonnesen <andreto@olsr.org>
Wed, 10 Nov 2004 16:58:46 +0000 (16:58 +0000)
src/olsr_plugin_io.h
src/plugin.c

index f39b914..5a57d20 100644 (file)
@@ -19,7 +19,7 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  * 
  * 
- * $Id: olsr_plugin_io.h,v 1.8 2004/11/07 12:19:58 kattemat Exp $
+ * $Id: olsr_plugin_io.h,v 1.9 2004/11/10 16:58:46 kattemat Exp $
  *
  */
 
@@ -35,6 +35,8 @@
  *                 GETD_MAXMESSAGESIZE removed
  *                 GETD_OUTPUTSIZE removed
  *                 GETF__NET_OUTBUFFER_PUSH added
+ *                 GETD__ROUTINGTABLE added
+ *                 GET__HNA_ROUTES added
  *                 - Andreas
  */
 
@@ -74,6 +76,8 @@
 #define GETD__TC_TABLE                             110
 #define GETD__HNA_SET                              111
 #define GETD__OLSR_CNF                             112
+#define GETD__ROUTINGTABLE                         113
+#define GETD__HNA_ROUTES                           114
 
 /* Function fetching - starts at 500 */
 #define GETF__OLSR_REGISTER_SCHEDULER_EVENT        500
index c8d3a87..796db0f 100644 (file)
@@ -19,7 +19,7 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  * 
  * 
- * $Id: plugin.c,v 1.9 2004/11/07 12:19:58 kattemat Exp $
+ * $Id: plugin.c,v 1.10 2004/11/10 16:58:46 kattemat Exp $
  *
  */
 
@@ -41,6 +41,7 @@
 #include "tc_set.h"
 #include "hna_set.h"
 #include "apm.h"
+#include "routing_table.h"
 
 /**
  * Multi-purpose function for plugins
@@ -91,6 +92,12 @@ olsr_plugin_io(int cmd, void *data, size_t size)
      case(GETD__OLSR_CNF):
       *((struct olsrd_config **)data) = olsr_cnf;
       break;
+      case(GETD__ROUTINGTABLE):
+      *((struct rt_entry **)data) = routingtable;
+      break;
+      case(GETD__HNA_ROUTES):
+      *((struct rt_entry **)data) = hna_routes;
+      break; 
 
       /* Function fetching */