aboutsummaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorEric Dumazet <eric.dumazet@gmail.com>2009-08-06 03:55:04 +0000
committerGreg Kroah-Hartman <gregkh@suse.de>2009-09-08 20:34:07 -0700
commit03300f07d8e955ef16b7bfcd62c77cb8cf5aab6a (patch)
tree7b88ed13e2f417ebd6880efcb2a1512befa1a118 /net
parent3020cf2a8341ebe53d689826fb569f309286e654 (diff)
irda: Fix irda_getname() leak
commit 09384dfc76e526c3993c09c42e016372dc9dd22c upstream. irda_getname() can leak kernel memory to user. Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'net')
-rw-r--r--net/irda/af_irda.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/irda/af_irda.c b/net/irda/af_irda.c
index e0fbcff6eb2..b06224bb06e 100644
--- a/net/irda/af_irda.c
+++ b/net/irda/af_irda.c
@@ -714,6 +714,7 @@ static int irda_getname(struct socket *sock, struct sockaddr *uaddr,
struct sock *sk = sock->sk;
struct irda_sock *self = irda_sk(sk);
+ memset(&saddr, 0, sizeof(saddr));
if (peer) {
if (sk->sk_state != TCP_ESTABLISHED)
return -ENOTCONN;