* [PATCH] libxtables: Print meaninful error message for an invalid MAC address string
@ 2014-02-02 18:39 Mart Frauenlob
2014-02-02 20:09 ` Pablo Neira Ayuso
0 siblings, 1 reply; 2+ messages in thread
From: Mart Frauenlob @ 2014-02-02 18:39 UTC (permalink / raw)
To: netfilter-devel
[-- Attachment #1: Type: text/plain, Size: 104 bytes --]
Hello,
on usage of a malformed MAC address the error message was not descriptive.
Best regards,
Mart
[-- Attachment #2: libxtables-Print-meaningful-error-message-for-an-invalid.patch --]
[-- Type: text/plain, Size: 1016 bytes --]
>From e2b3628a66db473d230e83a6eb98389849e20de1 Mon Sep 17 00:00:00 2001
From: Mart Frauenlob <mart.frauenlob@chello.at>
Date: Sun, 2 Feb 2014 14:24:25 +0100
Subject: [PATCH] libxtables: Print meaningful error message for an invalid MAC address string
If an invalid MAC address is used on the commmand line, the error message
`ether' was not really describing the problem.
Signed-off-by: Mart Frauenlob <mart.frauenlob@chello.at>
---
libxtables/xtoptions.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/libxtables/xtoptions.c b/libxtables/xtoptions.c
index 78e9abd..9b4c5aa 100644
--- a/libxtables/xtoptions.c
+++ b/libxtables/xtoptions.c
@@ -802,7 +802,7 @@ static void xtopt_parse_ethermac(struct xt_option_call *cb)
sizeof(cb->val.ethermac));
return;
out:
- xt_params->exit_err(PARAMETER_PROBLEM, "ether");
+ xt_params->exit_err(PARAMETER_PROBLEM, "Invalid MAC address specified.");
}
static void (*const xtopt_subparse[])(struct xt_option_call *) = {
--
1.7.2.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-02-02 20:09 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-02 18:39 [PATCH] libxtables: Print meaninful error message for an invalid MAC address string Mart Frauenlob
2014-02-02 20:09 ` Pablo Neira Ayuso
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).