summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorJames Morris <jmorris@namei.org>2006-07-31 07:21:45 +0400
committerDavid S. Miller <davem@sunset.davemloft.net>2006-08-03 00:38:18 +0400
commit118075b3cdc90e0815362365f3fc64d672ace0d6 (patch)
tree1309f0569f253086016286e9c55b02a63aedfd2d /net
parent9cac2c35e26cc44978df654306bb92d7cfe7e2de (diff)
downloadlinux-118075b3cdc90e0815362365f3fc64d672ace0d6.tar.xz
[TCP]: fix memory leak in net/ipv4/tcp_probe.c::tcpprobe_read()
Based upon a patch by Jesper Juhl. Signed-off-by: James Morris <jmorris@namei.org> Acked-by: Stephen Hemminger <shemminger@osdl.org> Acked-by: Jesper Juhl <jesper.juhl@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/ipv4/tcp_probe.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/tcp_probe.c b/net/ipv4/tcp_probe.c
index d7d517a3a238..b3435324b573 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)