aboutsummaryrefslogtreecommitdiff
path: root/src/libsunrpc/udp.c
diff options
context:
space:
mode:
authorrsc <devnull@localhost>2007-04-24 06:49:30 +0000
committerrsc <devnull@localhost>2007-04-24 06:49:30 +0000
commit5d3be932404680c053da66201f1e67af9a73f4d6 (patch)
treec2ce260c391cc012556036dde6ff3ad2304790dd /src/libsunrpc/udp.c
parent07029cdbbd9be6ad780bd594c98d26babec7ee67 (diff)
downloadplan9port-5d3be932404680c053da66201f1e67af9a73f4d6.tar.gz
plan9port-5d3be932404680c053da66201f1e67af9a73f4d6.tar.bz2
plan9port-5d3be932404680c053da66201f1e67af9a73f4d6.zip
fix memory leak (bakul shah)
Diffstat (limited to 'src/libsunrpc/udp.c')
-rw-r--r--src/libsunrpc/udp.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/libsunrpc/udp.c b/src/libsunrpc/udp.c
index 2e107e65..4a300030 100644
--- a/src/libsunrpc/udp.c
+++ b/src/libsunrpc/udp.c
@@ -92,8 +92,7 @@ sunudpwrite(void *v)
while((msg = recvp(arg.creply)) != nil){
if(udpwrite(arg.fd, &msg->udp, msg->msg.data, msg->msg.count) != msg->msg.count)
fprint(2, "udpwrite: %r\n");
- free(msg->msg.data);
- free(msg);
+ sunmsgdrop(&msg->msg);
}
}