From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.tuxdriver.com (charlotte.tuxdriver.com [70.61.120.58]) by dpdk.org (Postfix) with ESMTP id DDB505683 for ; Wed, 28 Sep 2016 21:30:14 +0200 (CEST) Received: from uucp by smtp.tuxdriver.com with local-rmail (Exim 4.63) (envelope-from ) id 1bpKYX-0000Pk-SP for dev@dpdk.org; Wed, 28 Sep 2016 15:30:13 -0400 Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by localhost.localdomain (8.15.2/8.14.6) with ESMTP id u8SJKApn020770 for ; Wed, 28 Sep 2016 15:20:10 -0400 Received: (from linville@localhost) by localhost.localdomain (8.15.2/8.15.2/Submit) id u8SJK9Ux020769 for dev@dpdk.org; Wed, 28 Sep 2016 15:20:09 -0400 X-Authentication-Warning: localhost.localdomain: linville set sender to linville@tuxdriver.com using -f From: "John W. Linville" To: dev@dpdk.org Date: Wed, 28 Sep 2016 15:20:03 -0400 Message-Id: <1475090404-20707-4-git-send-email-linville@tuxdriver.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1475090404-20707-1-git-send-email-linville@tuxdriver.com> References: <1475090404-20707-1-git-send-email-linville@tuxdriver.com> Subject: [dpdk-dev] [PATCH 3/4] i40e_vsi_release: do not use vsi until after NULL check X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 28 Sep 2016 19:30:15 -0000 Coverity: 127556 Signed-off-by: John W. Linville --- drivers/net/i40e/i40e_ethdev.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c index b04c833b2e04..d1f0f762b04c 100644 --- a/drivers/net/i40e/i40e_ethdev.c +++ b/drivers/net/i40e/i40e_ethdev.c @@ -4097,11 +4097,13 @@ i40e_vsi_release(struct i40e_vsi *vsi) void *temp; int ret; struct i40e_mac_filter *f; - uint16_t user_param = vsi->user_param; + uint16_t user_param; if (!vsi) return I40E_SUCCESS; + user_param = vsi->user_param; + pf = I40E_VSI_TO_PF(vsi); hw = I40E_VSI_TO_HW(vsi); -- 2.7.4