From mboxrd@z Thu Jan 1 00:00:00 1970 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) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga103.jf.intel.com with ESMTP; 20 Jun 2016 04:46:30 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.26,498,1459839600"; d="scan'208";a="722207933" Received: from yliu-dev.sh.intel.com (HELO yliu-dev) ([10.239.67.162]) by FMSMGA003.fm.intel.com with ESMTP; 20 Jun 2016 04:46:29 -0700 Date: Mon, 20 Jun 2016 19:47:25 +0800 From: Yuanhan Liu To: Remy Horton Cc: dev@dpdk.org, huawei.xie@intel.com 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 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) Subject: Re: [dpdk-dev] [PATCH] virtio: fix crash on querying xstats 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: Mon, 20 Jun 2016 11:46:31 -0000 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