diff options
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/ospfd/kroute.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.sbin/ospfd/kroute.c b/usr.sbin/ospfd/kroute.c index 0ef083e9a92..a146d95d7e1 100644 --- a/usr.sbin/ospfd/kroute.c +++ b/usr.sbin/ospfd/kroute.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kroute.c,v 1.57 2008/05/09 12:46:45 henning Exp $ */ +/* $OpenBSD: kroute.c,v 1.58 2008/06/13 07:05:26 claudio Exp $ */ /* * Copyright (c) 2004 Esben Norby <norby@openbsd.org> @@ -909,8 +909,8 @@ prefixlen2mask(u_int8_t prefixlen) return (htonl(0xffffffff << (32 - prefixlen))); } -#define ROUNDUP(a, size) \ - (((a) & ((size) - 1)) ? (1 + ((a) | ((size) - 1))) : (a)) +#define ROUNDUP(a) \ + (((a) & (sizeof(long) - 1)) ? (1 + ((a) | (sizeof(long) - 1))) : (a)) void get_rtaddrs(int addrs, struct sockaddr *sa, struct sockaddr **rti_info) @@ -921,7 +921,7 @@ get_rtaddrs(int addrs, struct sockaddr *sa, struct sockaddr **rti_info) if (addrs & (1 << i)) { rti_info[i] = sa; sa = (struct sockaddr *)((char *)(sa) + - ROUNDUP(sa->sa_len, sizeof(long))); + ROUNDUP(sa->sa_len)); } else rti_info[i] = NULL; } |