[Click] How to Get local IP Address

Zhiwei Yu linux_vpn at yahoo.com
Tue Jan 25 02:11:35 EST 2005


Hi,

I am looking for a solution to get all local addresses
in Click.  I have tried 2 methods, but neither works
with Click.  

At first, I tried to get from NETLINK in the user
space, as long as I load my element, the system
crashs.  I think it's easy to explain that Click
elements are actually running in the kernel space, the
netlink socket should not work with click.

After that, I have tried to get the device list from
"struct net_device * base_dev" in the kernel space, I
cannot compile my code, because the compiler always
complains some parameter is undeclared, although I
included <linux/netdevice.h> and <linux/inetdevice.h>.
 I really don't know how to handle this kind of
problems.  Any comments and helps will be greatly
appreciated.

Regards,
ZW


		
__________________________________ 
Do you Yahoo!? 
All your favorites on one personal page – Try My Yahoo!
http://my.yahoo.com 


More information about the click mailing list