diff options
Diffstat (limited to 'zebra/irdp_packet.c')
-rw-r--r-- | zebra/irdp_packet.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/zebra/irdp_packet.c b/zebra/irdp_packet.c index 77e559cc..2f448eca 100644 --- a/zebra/irdp_packet.c +++ b/zebra/irdp_packet.c @@ -305,11 +305,11 @@ send_packet(struct interface *ifp, icmp = (struct icmphdr *) (buf + sizeof (struct ip)); /* Merge IP header with icmp packet */ - - stream_get(icmp, s, s->putp); + assert (stream_get_endp(s) < (sizeof (buf) - sizeof (struct ip))); + stream_get(icmp, s, stream_get_endp(s)); /* icmp->checksum is already calculated */ - ip->ip_len = sizeof(struct ip) + s->putp; + ip->ip_len = sizeof(struct ip) + stream_get_endp(s); stream_free(s); on = 1; |