From: Eric Dumazet Date: Mon, 16 Aug 2010 03:25:00 +0000 (+0000) Subject: rds: fix a leak of kernel memory X-Git-Tag: MMI-PSA29.97-13-9~22097^2~186 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=f037590fff3005ce8a1513858d7d44f50053cc8f;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git rds: fix a leak of kernel memory struct rds_rdma_notify contains a 32 bits hole on 64bit arches, make sure it is zeroed before copying it to user. Signed-off-by: Eric Dumazet CC: Andy Grover Signed-off-by: David S. Miller --- diff --git a/net/rds/recv.c b/net/rds/recv.c index 795a00b7f2cb..c93588c2d553 100644 --- a/net/rds/recv.c +++ b/net/rds/recv.c @@ -297,7 +297,7 @@ static int rds_still_queued(struct rds_sock *rs, struct rds_incoming *inc, int rds_notify_queue_get(struct rds_sock *rs, struct msghdr *msghdr) { struct rds_notifier *notifier; - struct rds_rdma_notify cmsg; + struct rds_rdma_notify cmsg = { 0 }; /* fill holes with zero */ unsigned int count = 0, max_messages = ~0U; unsigned long flags; LIST_HEAD(copy);