diff options
author | Martin Mares <mj@ucw.cz> | 2002-03-10 13:32:12 +0100 |
---|---|---|
committer | Martin Mares <mj@ucw.cz> | 2002-03-10 13:32:12 +0100 |
commit | 53a50af50427e2fedc4bbfeca7a5934a798a3827 (patch) | |
tree | 078d15a5c5a959a7c7c8faebb24ca500c144c4b2 /proto | |
parent | e59e310e6435c6c72b585c6f4b5e6c9bbd006553 (diff) | |
download | bird-53a50af50427e2fedc4bbfeca7a5934a798a3827.tar bird-53a50af50427e2fedc4bbfeca7a5934a798a3827.zip |
Applied Pavel's fix for broadcast/multicast mode.
Diffstat (limited to 'proto')
-rw-r--r-- | proto/rip/rip.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/proto/rip/rip.c b/proto/rip/rip.c index d98f55e..68f9f1c 100644 --- a/proto/rip/rip.c +++ b/proto/rip/rip.c @@ -770,20 +770,19 @@ rip_if_notify(struct proto *p, unsigned c, struct iface *iface) if (c & IF_CHANGE_UP) { struct iface_patt *k = iface_patt_match(&P_CF->iface_list, iface); struct object_lock *lock; + struct rip_patt *PATT = (struct rip_patt *) k; if (!k) return; /* We are not interested in this interface */ lock = olock_new( p->pool ); + if (!(PATT->mode & IM_BROADCAST) && (iface->flags & IF_MULTICAST)) #ifndef IPV6 - lock->addr = ipa_from_u32(0xe0000009); /* This is okay: we - may actually use - other address, but - we do not want two - rips at one time, - anyway. */ + lock->addr = ipa_from_u32(0xe0000009); #else - ip_pton("FF02::9", &lock->addr); + ip_pton("FF02::9", &lock->addr); #endif + else + lock->addr = iface->addr->brd; lock->port = P_CF->port; lock->iface = iface; lock->hook = rip_real_if_add; |