NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kern/44647: routed sometimes thinls kernel routes disappear



This patch might help you.

Index: src/sbin/routed/if.c
===================================================================
RCS file: /cvsroot/src/sbin/routed/if.c,v
retrieving revision 1.29
diff -u -r1.29 if.c
--- src/sbin/routed/if.c        13 Oct 2010 09:19:40 -0000      1.29
+++ src/sbin/routed/if.c        28 Feb 2011 16:52:06 -0000
@@ -641,6 +641,9 @@
 #ifdef _HAVE_SA_LEN
        static struct sockaddr sa_zero;
 #endif
+#if defined(__NetBSD__) && defined(RT_ROUNDUP)
+#define ROUNDUP(a) RT_ROUNDUP(a)
+#else
 #ifdef sgi
 #define ROUNDUP(a) ((a) > 0 ? (1 + (((a) - 1) | (sizeof(__uint64_t) - 1))) \
                    : sizeof(__uint64_t))
@@ -648,6 +651,7 @@
 #define ROUNDUP(a) ((a) > 0 ? (1 + (((a) - 1) | (sizeof(long) - 1))) \
                    : sizeof(long))
 #endif
+#endif /* defined(__NetBSD__) && defined(RT_ROUNDUP) */
 
 
        memset(info, 0, sizeof(*info));

--
Takahiro HAYASHI



Home | Main Index | Thread Index | Old Index