Module Name: src Committed By: roy Date: Mon Dec 19 11:17:00 UTC 2016
Modified Files: src/sys/net: route.h Log Message: Fix gcc complaining about int to unsigned long conversion issues by explictly marking as unsigned in RT_ROUNDUP2. To generate a diff of this commit: cvs rdiff -u -r1.110 -r1.111 src/sys/net/route.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/net/route.h diff -u src/sys/net/route.h:1.110 src/sys/net/route.h:1.111 --- src/sys/net/route.h:1.110 Fri Dec 16 20:11:52 2016 +++ src/sys/net/route.h Mon Dec 19 11:17:00 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: route.h,v 1.110 2016/12/16 20:11:52 christos Exp $ */ +/* $NetBSD: route.h,v 1.111 2016/12/19 11:17:00 roy Exp $ */ /* * Copyright (c) 1980, 1986, 1993 @@ -286,7 +286,7 @@ struct rt_msghdr { #define RTAX_TAG 8 /* route tag */ #define RTAX_MAX 9 /* size of array to allocate */ -#define RT_ROUNDUP2(a, n) ((a) > 0 ? (1 + (((a) - 1) | ((n) - 1))) : (n)) +#define RT_ROUNDUP2(a, n) ((a) > 0 ? (1 + (((a) - 1U) | ((n) - 1))) : (n)) #define RT_ROUNDUP(a) RT_ROUNDUP2((a), sizeof(uint64_t)) #define RT_ADVANCE(x, n) (x += RT_ROUNDUP((n)->sa_len))