[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <51742849.80603@free.fr>
Date: Sun, 21 Apr 2013 19:56:25 +0200
From: "f6bvp@...e" <f6bvp@...e.fr>
To: netdev@...r.kernel.org, Mathias Krause <minipli@...glemail.com>
Subject: Re: [PATCH -next] netrom: fix invalid use of sizeof in nr_recvmsg()
Hi,
According to the proximity of NetRom and Rose codes I looked at af_rose.c
and it seems that similarly sockaddr_rose structure is let uninitialized
in rose_recvmsg().
Then, would you consider the following patch interesting to be committed ?
--- a/net/rose/af_rose.c 2013-04-17 07:11:28.000000000 +0200
+++ b/net/rose/af_rose.c 2013-04-21 17:26:06.914967897 +0200
@@ -1257,6 +1257,7 @@ static int rose_recvmsg(struct kiocb *io
skb_copy_datagram_iovec(skb, 0, msg->msg_iov, copied);
if (srose != NULL) {
+ memset(srose, 0, sizeof(*srose));
srose->srose_family = AF_ROSE;
srose->srose_addr = rose->dest_addr;
srose->srose_call = rose->dest_call;
Bernard Pidoux
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists