ifconfig: support (by ignoring it) "inet" before IP address or hostname

This commit is contained in:
Denis Vlasenko 2007-03-22 18:56:00 +00:00
parent 2a51af2579
commit 1787e22465

View File

@ -387,6 +387,8 @@ int ifconfig_main(int argc, char **argv)
} }
#endif #endif
else { else {
if (strcmp(host, "inet") == 0)
continue; /* compat stuff */
len_and_sockaddr *lsa = xhost2sockaddr(host, 0); len_and_sockaddr *lsa = xhost2sockaddr(host, 0);
#if ENABLE_FEATURE_IPV6 #if ENABLE_FEATURE_IPV6
if (lsa->sa.sa_family == AF_INET6) { if (lsa->sa.sa_family == AF_INET6) {