diff options
author | brian <brian@FreeBSD.org> | 1997-12-24 09:29:17 +0000 |
---|---|---|
committer | brian <brian@FreeBSD.org> | 1997-12-24 09:29:17 +0000 |
commit | 14d342e696e1f58935e230c2b5bda26daa36cda0 (patch) | |
tree | 73e0e9a6ac1b2542326d644b2e9f7611a6f6a810 /usr.sbin/ppp/iplist.c | |
parent | e2cdbfbbb2fff725814c29bd10d948ba15f8240e (diff) | |
download | FreeBSD-src-14d342e696e1f58935e230c2b5bda26daa36cda0.zip FreeBSD-src-14d342e696e1f58935e230c2b5bda26daa36cda0.tar.gz |
Cosmetic (style):
sizeof(var) -> sizeof var
sizeof type -> sizeof(type)
Suggested by: J Wunsch <j@uriah.heep.sax.de>
Diffstat (limited to 'usr.sbin/ppp/iplist.c')
-rw-r--r-- | usr.sbin/ppp/iplist.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/usr.sbin/ppp/iplist.c b/usr.sbin/ppp/iplist.c index e74add7..6e6ecd1 100644 --- a/usr.sbin/ppp/iplist.c +++ b/usr.sbin/ppp/iplist.c @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: iplist.c,v 1.2 1997/12/21 12:11:06 brian Exp $ + * $Id: iplist.c,v 1.3 1997/12/23 22:38:54 brian Exp $ */ #include <sys/types.h> @@ -149,8 +149,8 @@ iplist_next(struct iplist *list) int iplist_setsrc(struct iplist *list, const char *src) { - strncpy(list->src, src, sizeof(list->src)-1); - list->src[sizeof(list->src)-1] = '\0'; + strncpy(list->src, src, sizeof list->src - 1); + list->src[sizeof list->src - 1] = '\0'; list->cur.srcptr = list->src; do { if (iplist_nextrange(list)) @@ -211,7 +211,7 @@ iplist_ip2pos(struct iplist *list, struct in_addr ip) int f, result; result = -1; - memcpy(&cur, &list->cur, sizeof(cur)); + memcpy(&cur, &list->cur, sizeof cur); for (iplist_first(list), f = 0; f < list->nItems; f++) if (iplist_next(list).s_addr == ip.s_addr) { @@ -219,6 +219,6 @@ iplist_ip2pos(struct iplist *list, struct in_addr ip) break; } - memcpy(&list->cur, &cur, sizeof(list->cur)); + memcpy(&list->cur, &cur, sizeof list->cur); return result; } |