summaryrefslogtreecommitdiff
path: root/net/rxrpc
diff options
context:
space:
mode:
authorAlexey Dobriyan <adobriyan@gmail.com>2006-09-30 23:27:21 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-10-01 00:39:19 -0700
commit52978be636374c4bfb61220b37fa12f55a071c46 (patch)
tree36444be7bdbc0cdd99d903c0ad87316c93427517 /net/rxrpc
parent1a2f67b459bb7846d4a15924face63eb2683acc2 (diff)
downloadlinux-3.10-52978be636374c4bfb61220b37fa12f55a071c46.tar.gz
linux-3.10-52978be636374c4bfb61220b37fa12f55a071c46.tar.bz2
linux-3.10-52978be636374c4bfb61220b37fa12f55a071c46.zip
[PATCH] kmemdup: some users
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'net/rxrpc')
-rw-r--r--net/rxrpc/transport.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/rxrpc/transport.c b/net/rxrpc/transport.c
index 465efc86fcc..94b2e2fe6fd 100644
--- a/net/rxrpc/transport.c
+++ b/net/rxrpc/transport.c
@@ -381,11 +381,10 @@ static int rxrpc_incoming_msg(struct rxrpc_transport *trans,
/* allocate a new message record */
ret = -ENOMEM;
- msg = kmalloc(sizeof(struct rxrpc_message), GFP_KERNEL);
+ msg = kmemdup(jumbomsg, sizeof(struct rxrpc_message), GFP_KERNEL);
if (!msg)
goto error;
- memcpy(msg, jumbomsg, sizeof(*msg));
list_add_tail(&msg->link, msgq);
/* adjust the jumbo packet */