From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 14AE79E3 for ; Sun, 11 Sep 2016 14:37:47 +0200 (CEST) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga102.jf.intel.com with ESMTP; 11 Sep 2016 05:37:43 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.30,317,1470726000"; d="scan'208";a="1048712115" Received: from yliu-dev.sh.intel.com (HELO yliu-dev) ([10.239.67.162]) by orsmga002.jf.intel.com with ESMTP; 11 Sep 2016 05:37:42 -0700 Date: Sun, 11 Sep 2016 20:38:14 +0800 From: Yuanhan Liu To: Daniel Mrzyglod Cc: ferruh.yigit@intel.com, dev@dpdk.org, Thomas Monjalon Message-ID: <20160911123814.GC23158@yliu-dev.sh.intel.com> References: <1470224651-105433-1-git-send-email-danielx.t.mrzyglod@intel.com> <1470746235-122818-1-git-send-email-danielx.t.mrzyglod@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1470746235-122818-1-git-send-email-danielx.t.mrzyglod@intel.com> User-Agent: Mutt/1.5.23 (2014-03-12) Subject: Re: [dpdk-dev] [PATCH v2] examples/exception_path: fix shift operation in lcore setup 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: Sun, 11 Sep 2016 12:37:48 -0000 On Tue, Aug 09, 2016 at 02:37:15PM +0200, Daniel Mrzyglod wrote: > The operaton may have an undefined behavior or yield to an unexpected result. > A bit shift operation has a shift amount which is too large or has a negative value. > > As was mentioned in mailing list core list was limited to 64 so i changed bitmask > to core array > > Coverity issue: 30688 > Fixes: ea977ff1cb0b ("examples/exception_path: fix shift operation in lcore setup") > > Signed-off-by: Daniel Mrzyglod > --- ... > + if ((end == &tmp_char)) > + return -1; Hi, FYI, my testrobot caught some errors when this patch is applied. (BTW, gcc builds fine) --yliu --- x86_64-native-linuxapp-clang ============================ /root/dpdk/examples/exception_path/main.c:410:12: error: equality comparison with extraneous parentheses [-Werror,-Wparentheses-equality] if ((end == &tmp_char)) ~~~~^~~~~~~~~~~~ /root/dpdk/examples/exception_path/main.c:410:12: note: remove extraneous parentheses around the comparison to silence this warning if ((end == &tmp_char)) ~ ^ ~ /root/dpdk/examples/exception_path/main.c:410:12: note: use '=' to turn this equality comparison into an assignment if ((end == &tmp_char)) ^~ = 1 error generated. make[1]: *** [main.o] Error 1 make: *** [all] Error 2 error: build examples/exception_path failed error: build failed