All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] genl: Fix memory leak
@ 2014-12-15 11:07 Ravi kumar Veeramally
  2014-12-15 22:25 ` Denis Kenzior
  0 siblings, 1 reply; 2+ messages in thread
From: Ravi kumar Veeramally @ 2014-12-15 11:07 UTC (permalink / raw)
  To: ell

[-- Attachment #1: Type: text/plain, Size: 1361 bytes --]

==7322== Command: unit/test-genl
==7322==
==7322==
==7322== HEAP SUMMARY:
==7322==     in use at exit: 192 bytes in 5 blocks
==7322==   total heap usage: 17 allocs, 12 frees, 1,672 bytes allocated
==7322==
==7322== 192 (104 direct, 88 indirect) bytes in 1 blocks are definitely lost in loss record 5 of 5
==7322==    at 0x4C2ABA0: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==7322==    by 0x403D1D: l_malloc (util.c:62)
==7322==    by 0x402653: family_alloc (genl.c:144)
==7322==    by 0x4029FA: l_genl_new (genl.c:506)
==7322==    by 0x402BEF: l_genl_new_default (genl.c:548)
==7322==    by 0x400FDA: main (test-genl.c:49)
==7322==
==7322== LEAK SUMMARY:
==7322==    definitely lost: 104 bytes in 1 blocks
==7322==    indirectly lost: 88 bytes in 4 blocks
==7322==      possibly lost: 0 bytes in 0 blocks
==7322==    still reachable: 0 bytes in 0 blocks
==7322==         suppressed: 0 bytes in 0 blocks
---
 ell/genl.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/ell/genl.c b/ell/genl.c
index 88f73bc..dca8e1b 100644
--- a/ell/genl.c
+++ b/ell/genl.c
@@ -593,6 +593,8 @@ void l_genl_unref(struct l_genl *genl)
 	l_io_destroy(genl->io);
 	genl->io = NULL;
 
+	l_genl_family_unref(genl->nlctrl);
+
 	l_queue_destroy(genl->family_list, family_free);
 
 	if (genl->close_on_unref)
-- 
2.1.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] genl: Fix memory leak
  2014-12-15 11:07 [PATCH] genl: Fix memory leak Ravi kumar Veeramally
@ 2014-12-15 22:25 ` Denis Kenzior
  0 siblings, 0 replies; 2+ messages in thread
From: Denis Kenzior @ 2014-12-15 22:25 UTC (permalink / raw)
  To: ell

[-- Attachment #1: Type: text/plain, Size: 133 bytes --]

Hi Ravi,

 >   ell/genl.c | 2 ++
>   1 file changed, 2 insertions(+)
>

Patch has been applied, thanks.

Regards,
-Denis


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-12-15 22:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-12-15 11:07 [PATCH] genl: Fix memory leak Ravi kumar Veeramally
2014-12-15 22:25 ` Denis Kenzior

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.