diff options
author | Claudio Jeker <claudio@cvs.openbsd.org> | 2008-06-09 15:49:32 +0000 |
---|---|---|
committer | Claudio Jeker <claudio@cvs.openbsd.org> | 2008-06-09 15:49:32 +0000 |
commit | 56939efa355c7d584cd75c900aac071690574a7b (patch) | |
tree | 5d575fa1be9534087d2f533ee42af668db339b59 /usr.sbin | |
parent | 53264f5ef6f682ad1f22ed239d6cbf61bb395067 (diff) |
Correctly round the sockaddrs so that ndp works on 64bit machines.
Stupid sockaddr_in6 has the worst size possible.
OK henning@ deraadt@
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/ndp/ndp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/ndp/ndp.c b/usr.sbin/ndp/ndp.c index f032895f4ed..c4f0c00fb54 100644 --- a/usr.sbin/ndp/ndp.c +++ b/usr.sbin/ndp/ndp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ndp.c,v 1.41 2008/05/17 23:31:52 sobrado Exp $ */ +/* $OpenBSD: ndp.c,v 1.42 2008/06/09 15:49:31 claudio Exp $ */ /* $KAME: ndp.c,v 1.101 2002/07/17 08:46:33 itojun Exp $ */ /* @@ -874,7 +874,7 @@ rtmsg(int cmd) } #define NEXTADDR(w, s) \ if (rtm->rtm_addrs & (w)) { \ - bcopy((char *)&s, cp, sizeof(s)); cp += sizeof(s);} + bcopy((char *)&s, cp, sizeof(s)); cp += ROUNDUP(sizeof(s));} NEXTADDR(RTA_DST, sin_m); NEXTADDR(RTA_GATEWAY, sdl_m); |