diff options
-rw-r--r-- | include/nftables.h | 1 | ||||
-rw-r--r-- | src/datatype.c | 2 | ||||
-rw-r--r-- | src/main.c | 5 |
3 files changed, 5 insertions, 3 deletions
diff --git a/include/nftables.h b/include/nftables.h index ec21d37f..12f3c492 100644 --- a/include/nftables.h +++ b/include/nftables.h @@ -8,6 +8,7 @@ enum numeric_level { NUMERIC_NONE, NUMERIC_ADDR, + NUMERIC_PORT, NUMERIC_ALL, }; diff --git a/src/datatype.c b/src/datatype.c index 932acc7d..3eec931b 100644 --- a/src/datatype.c +++ b/src/datatype.c @@ -502,7 +502,7 @@ static void inet_service_type_print(const struct expr *expr) sin.sin_port = mpz_get_be16(expr->value); err = getnameinfo((struct sockaddr *)&sin, sizeof(sin), NULL, 0, buf, sizeof(buf), - numeric_output < NUMERIC_ALL ? 0 : NI_NUMERICSERV); + numeric_output < NUMERIC_PORT ? 0 : NI_NUMERICSERV); if (err != 0) { getnameinfo((struct sockaddr *)&sin, sizeof(sin), NULL, 0, buf, sizeof(buf), NI_NUMERICSERV); @@ -104,8 +104,9 @@ static void show_help(const char *name) " -i/--interactive Read input from interactive CLI\n" "\n" " -n/--numeric When specified once, show network addresses numerically.\n" -" When specified twice, also show Internet protocols,\n" -" Internet services, user IDs and group IDs numerically.\n" +" When specified twice, also show Internet services,\n" +" user IDs and group IDs numerically.\n" +" When specified thrice, also show protocols numerically.\n" " -a/--handle Output rule handle.\n" " -I/--includepath <directory> Add <directory> to the paths searched for include files.\n" #ifdef DEBUG |