linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] netfilter: xtables:  Remove unnecessary initialization of struct ts_state
@ 2014-09-08  7:51 Bojan Prtvar
  2014-09-09 10:02 ` Pablo Neira Ayuso
  0 siblings, 1 reply; 2+ messages in thread
From: Bojan Prtvar @ 2014-09-08  7:51 UTC (permalink / raw)
  To: pablo, kaber, kadlec, davem
  Cc: netfilter-devel, coreteam, netdev, linux-kernel

The skb_find_text() accepts uninitialized textsearch state variable.

Signed-off-by: Bojan Prtvar <prtvar.b@gmail.com>
---
 net/netfilter/xt_string.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/net/netfilter/xt_string.c b/net/netfilter/xt_string.c
index d3c48b1..5699adb 100644
--- a/net/netfilter/xt_string.c
+++ b/net/netfilter/xt_string.c
@@ -29,7 +29,6 @@ string_mt(const struct sk_buff *skb, struct xt_action_param *par)
 	struct ts_state state;
 	bool invert;
 
-	memset(&state, 0, sizeof(struct ts_state));
 	invert = conf->u.v1.flags & XT_STRING_FLAG_INVERT;
 
 	return (skb_find_text((struct sk_buff *)skb, conf->from_offset,
-- 
1.9.1.286.g5172cb3


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] netfilter: xtables:  Remove unnecessary initialization of struct ts_state
  2014-09-08  7:51 [PATCH] netfilter: xtables: Remove unnecessary initialization of struct ts_state Bojan Prtvar
@ 2014-09-09 10:02 ` Pablo Neira Ayuso
  0 siblings, 0 replies; 2+ messages in thread
From: Pablo Neira Ayuso @ 2014-09-09 10:02 UTC (permalink / raw)
  To: Bojan Prtvar
  Cc: kaber, kadlec, davem, netfilter-devel, coreteam, netdev, linux-kernel

On Mon, Sep 08, 2014 at 09:51:12AM +0200, Bojan Prtvar wrote:
> The skb_find_text() accepts uninitialized textsearch state variable.

Applied, thanks.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-09-09 10:01 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-09-08  7:51 [PATCH] netfilter: xtables: Remove unnecessary initialization of struct ts_state Bojan Prtvar
2014-09-09 10:02 ` 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).