2003-06-19 Paul Jakma <paul@dishone.st>

	* Fix lib/smux.c's reliance on daemons exporting struct
          thread_master *master.
diff --git a/ripd/rip_snmp.c b/ripd/rip_snmp.c
index 5a5060f..72f0ff2 100644
--- a/ripd/rip_snmp.c
+++ b/ripd/rip_snmp.c
@@ -152,6 +152,8 @@
   {RIP2PEERRCVBADROUTES,      COUNTER, RONLY, rip2PeerTable,
    3, {4, 1, 6}}
 };
+
+extern struct thread_master *master;
 
 static u_char *
 rip2Globals (struct variable *v, oid name[], size_t *length,
@@ -406,9 +408,9 @@
     return ripVersion1;
   else if (rip)
     {
-      if (rip->version == RIPv2)
+      if (rip->version_send == RIPv2)
 	return ripVersion2;
-      else if (rip->version == RIPv1)
+      else if (rip->version_send == RIPv1)
 	return ripVersion1;
     }
   return doNotSend;
@@ -573,7 +575,7 @@
 {
   rip_ifaddr_table = route_table_init ();
 
-  smux_init (ripd_oid, sizeof (ripd_oid) / sizeof (oid));
+  smux_init (master, ripd_oid, sizeof (ripd_oid) / sizeof (oid));
   REGISTER_MIB("mibII/rip", rip_variables, variable, rip_oid);
   smux_start ();
 }