From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Duan Jiong <duanj.fnst@cn.fujitsu.com>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [PATCH] netfilter: don't output error message redundantly
Date: Thu, 24 Jul 2014 13:49:46 +0200 [thread overview]
Message-ID: <20140724114946.GA21812@salvia> (raw)
In-Reply-To: <53CF53DD.6020308@cn.fujitsu.com>
On Wed, Jul 23, 2014 at 02:19:09PM +0800, Duan Jiong wrote:
>
> The function led_trigger_register() will only return -EEXIST when
> error arises.
>
> Signed-off-by: Duan Jiong <duanj.fnst@cn.fujitsu.com>
> ---
> net/netfilter/xt_LED.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/net/netfilter/xt_LED.c b/net/netfilter/xt_LED.c
> index 993de2b..b47a58c 100644
> --- a/net/netfilter/xt_LED.c
> +++ b/net/netfilter/xt_LED.c
> @@ -133,9 +133,7 @@ static int led_tg_check(const struct xt_tgchk_param *par)
>
> err = led_trigger_register(&ledinternal->netfilter_led_trigger);
> if (err) {
> - pr_warning("led_trigger_register() failed\n");
> - if (err == -EEXIST)
> - pr_warning("Trigger name is already in use.\n");
> + pr_warning("Trigger name is already in use.\n");
This should be pr_err() since the rule fails to be loaded if
led_trigger_register() fails.
next prev parent reply other threads:[~2014-07-24 11:49 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-23 6:19 [PATCH] netfilter: don't output error message redundantly Duan Jiong
2014-07-24 11:49 ` Pablo Neira Ayuso [this message]
2014-07-25 1:06 ` [PATCH v2] " Duan Jiong
2014-07-25 13:00 ` Pablo Neira Ayuso
2015-03-06 21:27 ` [PATCH] " Patrick McHardy
2015-03-06 21:29 ` Patrick McHardy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140724114946.GA21812@salvia \
--to=pablo@netfilter.org \
--cc=duanj.fnst@cn.fujitsu.com \
--cc=netfilter-devel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).