From 044d4d62b52c75a27d14cbb0592f4727ae76cf1a Mon Sep 17 00:00:00 2001 From: Bart De Schuymer Date: Thu, 11 Nov 2004 17:56:02 +0000 Subject: improve Ethernet proto error message --- userspace/ebtables2/ebtables.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/userspace/ebtables2/ebtables.c b/userspace/ebtables2/ebtables.c index 266ed8e..1e87fe3 100644 --- a/userspace/ebtables2/ebtables.c +++ b/userspace/ebtables2/ebtables.c @@ -470,6 +470,8 @@ static void parse_iface(char *iface, char *option) #define print_if_l_error ebt_print_error("Interface name length must be less " \ "than %d", IFNAMSIZ) +#define print_epoto_error(__proto) ebt_print_error("Problem with the specified"\ + " Ethernet protocol (%s), perhaps "_PATH_ETHERTYPES " is missing", __proto); #define OPT_COMMAND 0x01 #define OPT_TABLE 0x02 #define OPT_IN 0x04 @@ -964,8 +966,7 @@ handle_P: } ent = getethertypebyname(argv[optind - 1]); if (!ent) - ebt_print_error("Problem with the " - "specified protocol"); + print_epoto_error(argv[optind - 1]); new_entry->ethproto = ent->e_ethertype; } if (new_entry->ethproto < 1536 && -- cgit v1.2.3