86 |
#if ENABLE_FEATURE_IPCALC_LONG_OPTIONS |
#if ENABLE_FEATURE_IPCALC_LONG_OPTIONS |
87 |
applet_long_options = ipcalc_longopts; |
applet_long_options = ipcalc_longopts; |
88 |
#endif |
#endif |
89 |
opt = getopt32(argv, "mbn" USE_FEATURE_IPCALC_FANCY("phs")); |
opt = getopt32(argv, "mbn" IF_FEATURE_IPCALC_FANCY("phs")); |
90 |
argc -= optind; |
argc -= optind; |
91 |
argv += optind; |
argv += optind; |
92 |
if (opt & (BROADCAST | NETWORK | NETPREFIX)) { |
if (opt & (BROADCAST | NETWORK | NETPREFIX)) { |
178 |
|
|
179 |
hostinfo = gethostbyaddr((char *) &ipaddr, sizeof(ipaddr), AF_INET); |
hostinfo = gethostbyaddr((char *) &ipaddr, sizeof(ipaddr), AF_INET); |
180 |
if (!hostinfo) { |
if (!hostinfo) { |
181 |
bb_herror_msg_and_die("cannot find hostname for %s", argv[0]); |
bb_herror_msg_and_die("can't find hostname for %s", argv[0]); |
182 |
} |
} |
183 |
str_tolower(hostinfo->h_name); |
str_tolower(hostinfo->h_name); |
184 |
|
|