ipcs and mount commands uses -n key as namespace pointer
here we clear the place for similar option in net command
Signed-off-by: Vasily Averin <vvs(a)openvz.org>
---
help.c | 6 +++---
net.c | 4 ++--
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/help.c b/help.c
index 6aa3e20..780966b 100644
--- a/help.c
+++ b/help.c
@@ -6452,7 +6452,7 @@ NULL
char *help_net[] = {
"net",
"network command",
-"[-a] [[-s | -S [-xd]] [-R ref] [pid | taskp]] [-n addr]",
+"[-a] [[-s | -S [-xd]] [-R ref] [pid | taskp]] [-N addr]",
" Display various network related data:\n",
" -a display the ARP cache.",
" -s display open network socket/sock addresses, their family and
type,",
@@ -6462,7 +6462,7 @@ char *help_net[] = {
" of both structures.",
" -x override default output format with hexadecimal format.",
" -d override default output format with decimal format.",
-" -n addr translates an IPv4 address expressed as a decimal or hexadecimal",
+" -N addr translates an IPv4 address expressed as a decimal or hexadecimal",
" value into a standard numbers-and-dots notation.",
" -R ref socket or sock address, or file descriptor.",
" pid a process PID.",
@@ -6531,7 +6531,7 @@ char *help_net[] = {
" ...",
" "
" Translate the rcv_saddr from above into dotted-decimal notation:\n",
-" %s> net -n 1041236234",
+" %s> net -N 1041236234",
" 10.1.16.62",
" ",
" From \"foreach\", find all tasks with references to socket
c08ea3cc:\n",
diff --git a/net.c b/net.c
index 93491df..cdd424c 100644
--- a/net.c
+++ b/net.c
@@ -304,7 +304,7 @@ net_init(void)
* The net command...
*/
-#define NETOPTS "n:asSR:xd"
+#define NETOPTS "N:asSR:xd"
#define s_FLAG FOREACH_s_FLAG
#define S_FLAG FOREACH_S_FLAG
#define x_FLAG FOREACH_x_FLAG
@@ -351,7 +351,7 @@ cmd_net(void)
dump_arp();
break;
- case 'n':
+ case 'N':
value = stol(optarg, FAULT_ON_ERROR, NULL);
in_addr.s_addr = (in_addr_t)value;
fprintf(fp, "%s\n", inet_ntoa(in_addr));
--
1.9.1