Hello Harald,

> It does not depend on the output format, it depends on how you query
> the IP address. The host command only queries the remote DNS server and
> does NOT use local libc functions for name query. That is you directly
> send network packets to DNS server and parse server responses. On the
> other side this functionality is provided by the glibc library
> (resolver) hidden behind functions like gethostbyname or getaddrinfo,
> so you do not need manual DNS server query ... and then (if you use
> such functions) you shall model your output/applet after the 'getent
> hosts' command.


as said before, my needs are bound to getting the ip using dns as my usb
drive imaeg is "closed" in the matter that I don't want edit the hosts
file all the time.

so the "big" modification where should be either in gethostbyname or
getaddrinfo to be able to take /etc/hosts in account?

Eial.
_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to