aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/connector/connector.c
diff options
context:
space:
mode:
authorMathias Krause <minipli@googlemail.com>2013-09-30 16:03:08 -0400
committerDavid S. Miller <davem@davemloft.net>2013-10-02 16:03:50 -0400
commitac73bf50b709dea4e39635151b861b8a8f52bfbb (patch)
treef63b489a95edfd71781772370511fe16bb398fb0 /drivers/connector/connector.c
parent162b2bedc084d2d908a04c93383ba02348b648b0 (diff)
connector: use 'size' everywhere in cn_netlink_send()
We calculated the size for the netlink message buffer as size. Use size in the memcpy() call as well instead of recalculating it. Signed-off-by: Mathias Krause <minipli@googlemail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/connector/connector.c')
-rw-r--r--drivers/connector/connector.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/connector/connector.c b/drivers/connector/connector.c
index 0daa11e418b1..a36749f1e44a 100644
--- a/drivers/connector/connector.c
+++ b/drivers/connector/connector.c
@@ -109,7 +109,7 @@ int cn_netlink_send(struct cn_msg *msg, u32 __group, gfp_t gfp_mask)
109 109
110 data = nlmsg_data(nlh); 110 data = nlmsg_data(nlh);
111 111
112 memcpy(data, msg, sizeof(*data) + msg->len); 112 memcpy(data, msg, size);
113 113
114 NETLINK_CB(skb).dst_group = group; 114 NETLINK_CB(skb).dst_group = group;
115 115