From 7e94bcac88e16c22b8258bcdcb4b2165b198679a Mon Sep 17 00:00:00 2001 From: Daiki Ueno Date: Wed, 21 Sep 2016 15:06:41 +0200 Subject: rpc: Fix memleak in rpc_socket cleanup GCC's asan spotted this: Direct leak of 120 byte(s) in 1 object(s) allocated from: #0 0x7f8d4f221fe0 in calloc (/lib64/libasan.so.3+0xc6fe0) #1 0x427f55 in rpc_socket_new ../p11-kit/rpc-transport.c:100 #2 0x42bc1b in rpc_exec_connect ../p11-kit/rpc-transport.c:767 --- p11-kit/rpc-transport.c | 1 + 1 file changed, 1 insertion(+) diff --git a/p11-kit/rpc-transport.c b/p11-kit/rpc-transport.c index 5251e11..13d1372 100644 --- a/p11-kit/rpc-transport.c +++ b/p11-kit/rpc-transport.c @@ -163,6 +163,7 @@ rpc_socket_unref (rpc_socket *sock) rpc_socket_close (sock); p11_mutex_uninit (&sock->write_lock); p11_mutex_uninit (&sock->read_lock); + free (sock); } static bool -- cgit v1.1