"Robert P. J. Day" | 63fc1a9 | 2006-07-02 19:47:05 +0000 | [diff] [blame] | 1 | /* vi: set sw=4 ts=4: */ |
Eric Andersen | c223ced | 2001-11-10 12:18:42 +0000 | [diff] [blame] | 2 | /* |
| 3 | * stolen from net-tools-1.59 and stripped down for busybox by |
Eric Andersen | cb81e64 | 2003-07-14 21:21:08 +0000 | [diff] [blame] | 4 | * Erik Andersen <andersen@codepoet.org> |
Eric Andersen | c223ced | 2001-11-10 12:18:42 +0000 | [diff] [blame] | 5 | * |
| 6 | * Heavily modified by Manuel Novoa III Mar 12, 2001 |
| 7 | * |
Eric Andersen | c223ced | 2001-11-10 12:18:42 +0000 | [diff] [blame] | 8 | */ |
| 9 | |
Rob Landley | dae6aa2 | 2006-03-09 22:39:08 +0000 | [diff] [blame] | 10 | #include "platform.h" |
Eric Andersen | c223ced | 2001-11-10 12:18:42 +0000 | [diff] [blame] | 11 | |
Eric Andersen | c223ced | 2001-11-10 12:18:42 +0000 | [diff] [blame] | 12 | /* hostfirst!=0 If we expect this to be a hostname, |
| 13 | try hostname database first |
| 14 | */ |
| 15 | extern int INET_resolve(const char *name, struct sockaddr_in *s_in, int hostfirst); |
| 16 | |
Denis Vlasenko | 7ca3921 | 2006-11-21 20:34:21 +0000 | [diff] [blame] | 17 | /* numeric: & 0x8000: "default" instead of "*", |
Eric Andersen | c223ced | 2001-11-10 12:18:42 +0000 | [diff] [blame] | 18 | * & 0x4000: host instead of net, |
| 19 | * & 0x0fff: don't resolve |
| 20 | */ |
| 21 | extern int INET_rresolve(char *name, size_t len, struct sockaddr_in *s_in, |
| 22 | int numeric, unsigned int netmask); |
Eric Andersen | 51b8bd6 | 2002-07-03 11:46:38 +0000 | [diff] [blame] | 23 | |
Manuel Novoa III | 7d0c519 | 2004-03-10 07:42:38 +0000 | [diff] [blame] | 24 | extern int INET6_resolve(const char *name, struct sockaddr_in6 *sin6); |
Eric Andersen | 51b8bd6 | 2002-07-03 11:46:38 +0000 | [diff] [blame] | 25 | extern int INET6_rresolve(char *name, size_t len, struct sockaddr_in6 *sin6, int numeric); |