aboutsummaryrefslogtreecommitdiff
path: root/networking/ipcalc.c
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2012-03-22 14:11:12 +0000
committerRon Yorston <rmy@pobox.com>2012-03-22 14:11:12 +0000
commit67758035a4fe040c6ac69b39d61bcd6bddd7b827 (patch)
treea4a1db7f54c16d12fabe2626b8f1e235cd694e9e /networking/ipcalc.c
parent811c449748d5bd0505f8510e5582892f94ac0cda (diff)
parentb83c9704128dd106071184e4b00335a3b8486857 (diff)
downloadbusybox-w32-67758035a4fe040c6ac69b39d61bcd6bddd7b827.tar.gz
busybox-w32-67758035a4fe040c6ac69b39d61bcd6bddd7b827.tar.bz2
busybox-w32-67758035a4fe040c6ac69b39d61bcd6bddd7b827.zip
Merge commit 'b83c9704128dd106071184e4b00335a3b8486857' into merge
Diffstat (limited to 'networking/ipcalc.c')
-rw-r--r--networking/ipcalc.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/networking/ipcalc.c b/networking/ipcalc.c
index acbaa4ac5..f96c73912 100644
--- a/networking/ipcalc.c
+++ b/networking/ipcalc.c
@@ -11,6 +11,33 @@
11 * 11 *
12 * Licensed under GPLv2 or later, see file LICENSE in this source tree. 12 * Licensed under GPLv2 or later, see file LICENSE in this source tree.
13 */ 13 */
14
15//usage:#define ipcalc_trivial_usage
16//usage: "[OPTIONS] ADDRESS[[/]NETMASK] [NETMASK]"
17//usage:#define ipcalc_full_usage "\n\n"
18//usage: "Calculate IP network settings from a IP address\n"
19//usage: "\nOptions:"
20//usage: IF_FEATURE_IPCALC_LONG_OPTIONS(
21//usage: "\n -b,--broadcast Display calculated broadcast address"
22//usage: "\n -n,--network Display calculated network address"
23//usage: "\n -m,--netmask Display default netmask for IP"
24//usage: IF_FEATURE_IPCALC_FANCY(
25//usage: "\n -p,--prefix Display the prefix for IP/NETMASK"
26//usage: "\n -h,--hostname Display first resolved host name"
27//usage: "\n -s,--silent Don't ever display error messages"
28//usage: )
29//usage: )
30//usage: IF_NOT_FEATURE_IPCALC_LONG_OPTIONS(
31//usage: "\n -b Display calculated broadcast address"
32//usage: "\n -n Display calculated network address"
33//usage: "\n -m Display default netmask for IP"
34//usage: IF_FEATURE_IPCALC_FANCY(
35//usage: "\n -p Display the prefix for IP/NETMASK"
36//usage: "\n -h Display first resolved host name"
37//usage: "\n -s Don't ever display error messages"
38//usage: )
39//usage: )
40
14#include "libbb.h" 41#include "libbb.h"
15/* After libbb.h, because on some systems it needs other includes */ 42/* After libbb.h, because on some systems it needs other includes */
16#include <arpa/inet.h> 43#include <arpa/inet.h>