[PATCH] libxtables: Print meaninful error message for an invalid MAC address string

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

on usage of a malformed MAC address the error message was not descriptive.

Best regards,

Mart
>From e2b3628a66db473d230e83a6eb98389849e20de1 Mon Sep 17 00:00:00 2001
From: Mart Frauenlob <mart.frauenlob@xxxxxxxxx>
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@xxxxxxxxx>
---
 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


[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux