summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ripd/ChangeLog5
-rw-r--r--ripd/ripd.c5
2 files changed, 8 insertions, 2 deletions
diff --git a/ripd/ChangeLog b/ripd/ChangeLog
index 5820f424..0d7b5bcd 100644
--- a/ripd/ChangeLog
+++ b/ripd/ChangeLog
@@ -1,3 +1,8 @@
+2004-03-18 sowmini.varadhan@sun.com
+
+ * ripd.c: rip_send_packet can get null connected address when
+ called in response to a unicast rip-request. Handle correctly.
+
2004-03-03 Krzysztof Oledzki <oleq@ans.pl>
* ripd.c: fix "show ip rip" and per interface rip version selection.
diff --git a/ripd/ripd.c b/ripd/ripd.c
index a69963be..22777e50 100644
--- a/ripd/ripd.c
+++ b/ripd/ripd.c
@@ -1253,9 +1253,10 @@ rip_send_packet (caddr_t buf, int size, struct sockaddr_in *to,
strcpy(dst, inet_ntoa(sin.sin_addr));
}
zlog_info("rip_send_packet %s > %s (%s)",
- inet_ntoa(connected->address->u.prefix4), dst, ifp->name);
+ (connected ? inet_ntoa(connected->address->u.prefix4) : ""),
+ dst, ifp->name);
}
- if (connected->flags & ZEBRA_IFA_SECONDARY)
+ if (connected && connected->flags & ZEBRA_IFA_SECONDARY)
{
/*
* ZEBRA_IFA_SECONDARY is set on linux when an interface is configured