Re: network interface/address API on FreeBSD

2015-03-04 Thread Niels Baggesen
Den 04-03-2015 kl. 10:17 skrev Gleb Smirnoff: I see, you use { CTL_NET, PF_ROUTE, 0, 0, NET_RT_IFLIST, 0 }; I'd suggest to use getifaddrs(3), it uses more modern sysctl NET_RT_IFLISTL, note the L at end. And the library function takes the burden of parsing the stuff. That looks interesting.

Re: network interface/address API on FreeBSD

2015-03-04 Thread Gleb Smirnoff
Niels, On Wed, Mar 04, 2015 at 09:06:11PM +0100, Niels Baggesen wrote: N Den 04-03-2015 kl. 10:17 skrev Gleb Smirnoff: N I see, you use { CTL_NET, PF_ROUTE, 0, 0, NET_RT_IFLIST, 0 }; N N I'd suggest to use getifaddrs(3), it uses more modern sysctl N NET_RT_IFLISTL, note the L at end. And

Re: network interface/address API on FreeBSD

2015-03-04 Thread Gleb Smirnoff
On Mon, Mar 02, 2015 at 09:33:30PM +0100, Niels Baggesen wrote: N Den 27-02-2015 kl. 22:22 skrev Gleb Smirnoff: N Now time for net-snmp, which isn't piece of cake. And I'd like N to get it done properly, and not to store a patch in FreeBSD port N for ages, but to integrate the patch right in

network interface/address API on FreeBSD

2015-03-03 Thread Gleb Smirnoff
Hi! [I'm not subscribed to the list, so please keep me in Cc] I'm the guy, who often breaks compilation of net-snmp on FreeBSD, changing layout of kernel structures. And I'm about to change them even more this year. However, I'd like to keep net-snmp working. But it looks like, I won't be

Re: network interface/address API on FreeBSD

2015-03-03 Thread Gleb Smirnoff
On Mon, Mar 02, 2015 at 09:33:30PM +0100, Niels Baggesen wrote: N Den 27-02-2015 kl. 22:22 skrev Gleb Smirnoff: N Now time for net-snmp, which isn't piece of cake. And I'd like N to get it done properly, and not to store a patch in FreeBSD port N for ages, but to integrate the patch right in

Re: network interface/address API on FreeBSD

2015-03-02 Thread Niels Baggesen
Den 27-02-2015 kl. 22:22 skrev Gleb Smirnoff: Now time for net-snmp, which isn't piece of cake. And I'd like to get it done properly, and not to store a patch in FreeBSD port for ages, but to integrate the patch right in the main net-snmp repo. So, I'm asking for your help here. Waiting for a

network interface/address API on FreeBSD

2015-02-27 Thread Gleb Smirnoff
Hi! I'm the guy, who often breaks compilation of net-snmp on FreeBSD, changing layout of kernel structures. And I'm about to change them even more this year. However, I'd like to keep net-snmp working. But it looks like, I won't be able to do that without your help, since patches are about to