From: Andreas Steffen <andreas.steffen@strongswan.org>
To: netdev@vger.kernel.org
Cc: jamal <hadi@cyberus.ca>, David Miller <davem@davemloft.net>
Subject: [PATCH] xfrm: fix XFRMA_MARK extraction in xfrm_mark_get
Date: Wed, 30 Jun 2010 09:57:34 +0200 [thread overview]
Message-ID: <4C2AF8EE.8030508@strongswan.org> (raw)
Determine the size of the xfrm_mark struct, not of its pointer.
Signed-off-by: Andreas Steffen <andreas.steffen@strongswan.org>
---
include/net/xfrm.h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/include/net/xfrm.h b/include/net/xfrm.h
index 1913af6..fc8f36d 100644
--- a/include/net/xfrm.h
+++ b/include/net/xfrm.h
@@ -1586,7 +1586,7 @@ static inline struct xfrm_state *xfrm_input_state(struct sk_buff *skb)
static inline int xfrm_mark_get(struct nlattr **attrs, struct xfrm_mark *m)
{
if (attrs[XFRMA_MARK])
- memcpy(m, nla_data(attrs[XFRMA_MARK]), sizeof(m));
+ memcpy(m, nla_data(attrs[XFRMA_MARK]), sizeof(struct xfrm_mark));
else
m->v = m->m = 0;
--
1.7.0.4
next reply other threads:[~2010-06-30 9:14 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-30 7:57 Andreas Steffen [this message]
2010-06-30 10:07 ` [PATCH] xfrm: fix XFRMA_MARK extraction in xfrm_mark_get jamal
2010-06-30 17:41 ` David Miller
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=4C2AF8EE.8030508@strongswan.org \
--to=andreas.steffen@strongswan.org \
--cc=davem@davemloft.net \
--cc=hadi@cyberus.ca \
--cc=netdev@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).