From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id 40CD52C6E for ; Mon, 23 Jan 2017 08:46:59 +0100 (CET) Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga104.fm.intel.com with ESMTP; 22 Jan 2017 23:46:58 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,273,1477983600"; d="scan'208";a="51486175" Received: from yliu-dev.sh.intel.com ([10.239.67.162]) by orsmga004.jf.intel.com with ESMTP; 22 Jan 2017 23:46:58 -0800 From: Yuanhan Liu To: Yong Wang Cc: Yuanhan Liu , dpdk stable Date: Mon, 23 Jan 2017 15:47:48 +0800 Message-Id: <1485157675-32114-73-git-send-email-yuanhan.liu@linux.intel.com> X-Mailer: git-send-email 1.9.0 In-Reply-To: <1485157675-32114-1-git-send-email-yuanhan.liu@linux.intel.com> References: <1485157675-32114-1-git-send-email-yuanhan.liu@linux.intel.com> Subject: [dpdk-stable] patch 'vhost: fix memory leak' has been queued to stable release 16.11.1 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 Jan 2017 07:46:59 -0000 Hi, FYI, your patch has been queued to stable release 16.11.1 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 01/28/17. So please shout if anyone has objections. --- Note 16.11 is a LTS release. v16.11.1 is planned to be released shortly (about 2-3 weeks) after v17.02. --- Thanks. --yliu --- >>From c3b125f1f78f434e5579ba36a98027eef02703fa Mon Sep 17 00:00:00 2001 From: Yong Wang Date: Tue, 3 Jan 2017 22:57:55 -0500 Subject: [PATCH] vhost: fix memory leak [ upstream commit 5731d6acc7fe1f76ed895d08821b51dd5c817bd0 ] In function vhost_new_device(), current code dose not free 'dev' in "i == MAX_VHOST_DEVICE" condition statements. It will lead to a memory leak. Fixes: 45ca9c6f7bc6 ("vhost: get rid of linked list for devices") Signed-off-by: Yong Wang Acked-by: Yuanhan Liu --- lib/librte_vhost/vhost.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/librte_vhost/vhost.c b/lib/librte_vhost/vhost.c index 31825b8..e415093 100644 --- a/lib/librte_vhost/vhost.c +++ b/lib/librte_vhost/vhost.c @@ -250,6 +250,7 @@ vhost_new_device(void) if (i == MAX_VHOST_DEVICE) { RTE_LOG(ERR, VHOST_CONFIG, "Failed to find a free slot for new device.\n"); + rte_free(dev); return -1; } -- 1.9.0