How to print the foreign port (under netinet tcpip code)

This is my first post on FreeBSD. Hello all.

I am currently doing some debugging. I would like to view the foreign port in a socket (incoming connection). I tried sotoinpbc(so)->inp_fport but that only shows 0 as the foreign port.

Thanks
 
Back
Top