Peter,

Just backport the inet_ntoa() and inet_ntoa6() subroutines. I don't think
it's worth faking something up.

Adam

On Wed, Oct 22, 2008 at 05:03:09PM -0400, Peter Cudhea wrote:
> I am writing a Dtrace script for a context (Solaris 10) in which the 
> built-in functions inet_ntoa and inet_ntoa6 are not available.   The 
> input is a userland address to a sockddr_in structure.   
> 
> Does anyone have a pointer to a working example of D code that takes a 
> userland pointer to a sockaddr or ip address, dereferences it using 
> copyin, and formats it using strjoin into "dotted decimal" form?  
> 
> The closest I have found is the magic in Brendan's tcpsnoop to do 
> something similar with the kernel-side IP addresses.   This is useful.  
> I am hoping for something even closer to what I need.
> 
> Peter
> _______________________________________________
> dtrace-discuss mailing list
> dtrace-discuss@opensolaris.org

-- 
Adam Leventhal, Fishworks                     http://blogs.sun.com/ahl
_______________________________________________
dtrace-discuss mailing list
dtrace-discuss@opensolaris.org

Reply via email to