Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 Jul 2012 17:52:11 +0200
From:      Luigi Rizzo <rizzo@iet.unipi.it>
To:        current@freebsd.org
Subject:   RFC: libkern version of inet_ntoa_r
Message-ID:  <20120725155211.GA33971@onelab2.iet.unipi.it>

next in thread | raw e-mail | index | archive | help
During some ipfw/dummynet cleanup i noticed that the libkern version of
inet_ntoa_r() is missing the buffer size argument that is present in
the libc counterpart.

Any objection if i fix it ?
The change is trivial and the function is used only in a small number
of places, see below (some of which are even commented out).

# (cd ~/FreeBSD/head/sys; grep -r inet_ntoa_r .)
./libkern/inet_ntoa.c:inet_ntoa_r(struct in_addr ina, char *buf)
./net/flowtable.c:              inet_ntoa_r(ssin->sin_addr, saddr);
./net/flowtable.c:              inet_ntoa_r(dsin->sin_addr, daddr);
./net/flowtable.c:              inet_ntoa_r(*(struct in_addr *) &dsin->sin_addr, daddr);
./net/flowtable.c:      inet_ntoa_r(*(struct in_addr *) &hashkey[2], daddr);
./net/flowtable.c:              inet_ntoa_r(*(struct in_addr *) &hashkey[1], saddr);            
./net/if_llatbl.c:              inet_ntoa_r(sin->sin_addr, l3s);
./netinet/ipfw/ip_fw_dynamic.c:         inet_ntoa_r(da, src);
./netinet/ipfw/ip_fw_dynamic.c:         inet_ntoa_r(da, dst);
./netinet/ipfw/ip_fw_dynamic.c:                 inet_ntoa_r(da, src);
./netinet/ipfw/ip_fw_dynamic.c:                 inet_ntoa_r(da, dst);
./netinet/ipfw/ip_fw_dynamic.c:         inet_ntoa_r(da, src);
./netinet/ipfw/ip_fw_dynamic.c:         inet_ntoa_r(da, dst);
./netinet/ipfw/ip_fw_dynamic.c:                                         inet_ntoa_r(da, src);
./netinet/ipfw/ip_fw_dynamic.c:                                         inet_ntoa_r(da, dst);
./netinet/ipfw/ip_fw_log.c:                     inet_ntoa_r(ip->ip_src, src);
./netinet/ipfw/ip_fw_log.c:                     inet_ntoa_r(ip->ip_dst, dst);
./netinet/in.h:char     *inet_ntoa_r(struct in_addr ina, char *buf); /* in libkern */
./netinet/in_pcb.c:             inet_ntoa_r(inc->inc_laddr, laddr_str);
./netinet/in_pcb.c:             inet_ntoa_r(inc->inc_faddr, faddr_str);
./netinet/tcp_subr.c:           inet_ntoa_r(inc->inc_faddr, sp);
./netinet/tcp_subr.c:           inet_ntoa_r(inc->inc_laddr, sp);
./netinet/tcp_subr.c:           inet_ntoa_r(ip->ip_src, sp);
./netinet/tcp_subr.c:           inet_ntoa_r(ip->ip_dst, sp);

cheers
luigi



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120725155211.GA33971>