diff mbox

[ipsec] af_key: initialize satype in key_notify_policy_flush()

Message ID 1361201060-31732-1-git-send-email-nicolas.dichtel@6wind.com
State Awaiting Upstream, archived
Delegated to: David Miller
Headers show

Commit Message

Nicolas Dichtel Feb. 18, 2013, 3:24 p.m. UTC
This field was left uninitialized. Some user daemons perform check against this
field.

Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
---
 net/key/af_key.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Steffen Klassert Feb. 22, 2013, 5:56 a.m. UTC | #1
On Mon, Feb 18, 2013 at 04:24:20PM +0100, Nicolas Dichtel wrote:
> This field was left uninitialized. Some user daemons perform check against this
> field.
> 
> Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>

Applied, thanks!
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/net/key/af_key.c b/net/key/af_key.c
index 5b426a6..f9bd41e 100644
--- a/net/key/af_key.c
+++ b/net/key/af_key.c
@@ -2688,6 +2688,7 @@  static int key_notify_policy_flush(const struct km_event *c)
 	hdr->sadb_msg_pid = c->portid;
 	hdr->sadb_msg_version = PF_KEY_V2;
 	hdr->sadb_msg_errno = (uint8_t) 0;
+	hdr->sadb_msg_satype = SADB_SATYPE_UNSPEC;
 	hdr->sadb_msg_len = (sizeof(struct sadb_msg) / sizeof(uint64_t));
 	pfkey_broadcast(skb_out, GFP_ATOMIC, BROADCAST_ALL, NULL, c->net);
 	return 0;