From 2477924e34a9a0827a0ac0790f442d94f254117c Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Wed, 15 Aug 2012 15:19:18 -0700 Subject: [PATCH] dpif-netdev: Fix memory leak. upcall->packet is allocated with malloc(), via ofpbuf_new(), but nothing ever frees it. Found by valgrind. CC: Ed Maste Signed-off-by: Ben Pfaff --- lib/dpif-netdev.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c index 7fa272084..3d01b17aa 100644 --- a/lib/dpif-netdev.c +++ b/lib/dpif-netdev.c @@ -966,6 +966,7 @@ dpif_netdev_recv(struct dpif *dpif, struct dpif_upcall *upcall, ofpbuf_uninit(buf); *buf = *upcall->packet; + free(upcall->packet); return 0; } else { -- 2.43.0