From: James Morris Date: Mon, 31 Jul 2006 03:21:45 +0000 (-0700) Subject: [TCP]: fix memory leak in net/ipv4/tcp_probe.c::tcpprobe_read() X-Git-Tag: v2.6.18-rc4~65^2~21 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=118075b3cdc90e0815362365f3fc64d672ace0d6;p=platform%2Fkernel%2Flinux-3.10.git [TCP]: fix memory leak in net/ipv4/tcp_probe.c::tcpprobe_read() Based upon a patch by Jesper Juhl. Signed-off-by: James Morris Acked-by: Stephen Hemminger Acked-by: Jesper Juhl Signed-off-by: David S. Miller --- diff --git a/net/ipv4/tcp_probe.c b/net/ipv4/tcp_probe.c index d7d517a..b343532 100644 --- a/net/ipv4/tcp_probe.c +++ b/net/ipv4/tcp_probe.c @@ -114,7 +114,7 @@ static int tcpprobe_open(struct inode * inode, struct file * file) static ssize_t tcpprobe_read(struct file *file, char __user *buf, size_t len, loff_t *ppos) { - int error = 0, cnt; + int error = 0, cnt = 0; unsigned char *tbuf; if (!buf || len < 0)