From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yuanhan Liu Subject: Re: [PATCH] virtio: fix crash on querying xstats Date: Mon, 20 Jun 2016 19:47:25 +0800 Message-ID: <20160620114725.GI23111@yliu-dev.sh.intel.com> References: <1466419843-1321-1-git-send-email-yuanhan.liu@linux.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: dev@dpdk.org, huawei.xie@intel.com To: Remy Horton Return-path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id 236BA2BDE for ; Mon, 20 Jun 2016 13:46:31 +0200 (CEST) Content-Disposition: inline In-Reply-To: List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Mon, Jun 20, 2016 at 12:02:16PM +0100, Remy Horton wrote: > > On 20/06/2016 11:50, Yuanhan Liu wrote: > >Trying to access xstats_names after "if (stats_names == NULL)" is > >obviously wrong, which would result to a crash while running "show > >port xstats 0" in testpmd with virtio PMD. > > > >The fix is also straightforward: just revese the check. > > > >Fixes: baf91c395b18 ("net/virtio: fetch extended statistics with integer ids") > > > >Cc: Remy Horton > >Signed-off-by: Yuanhan Liu > > Acked-by: Remy Horton Applied to dpdk-next-virtio. --yliu