From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751257AbdALSKM (ORCPT ); Thu, 12 Jan 2017 13:10:12 -0500 Received: from mail.kernel.org ([198.145.29.136]:46086 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750779AbdALSIn (ORCPT ); Thu, 12 Jan 2017 13:08:43 -0500 Date: Thu, 12 Jan 2017 15:07:50 -0300 From: Arnaldo Carvalho de Melo To: Arnaldo Carvalho de Melo Cc: Jiri Olsa , Andi Kleen , jolsa@kernel.org, linux-kernel@vger.kernel.org, mingo@kernel.org, Andi Kleen Subject: Re: [PATCH 01/11] perf, tools: Factor out scale conversion code Message-ID: <20170112180750.GC20003@kernel.org> References: <20170103150833.6694-1-andi@firstfloor.org> <20170103150833.6694-2-andi@firstfloor.org> <20170108185753.GC14072@krava> <20170112133157.GA20003@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170112133157.GA20003@kernel.org> X-Url: http://acmel.wordpress.com User-Agent: Mutt/1.7.1 (2016-10-04) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Thu, Jan 12, 2017 at 10:31:57AM -0300, Arnaldo Carvalho de Melo escreveu: > Em Sun, Jan 08, 2017 at 07:57:53PM +0100, Jiri Olsa escreveu: > > On Tue, Jan 03, 2017 at 07:08:23AM -0800, Andi Kleen wrote: > > > > SNIP > > > > > - goto error; > > > - > > > - if (scale[sret - 1] == '\n') > > > - scale[sret - 1] = '\0'; > > > - else > > > - scale[sret] = '\0'; > > > + int ret = 0; > > > > > > /* > > > * save current locale > > > @@ -133,8 +111,8 @@ static int perf_pmu__parse_scale(struct perf_pmu_alias *alias, char *dir, char * > > > */ > > > lc = strdup(lc); > > > if (!lc) { > > > - ret = -ENOMEM; > > > - goto error; > > > + ret = -1; > > > + goto out; > > > > not sure why you changed the -ENOMEM to -1 ;-) but it's ok anyway > > These unrelated things are just that, noise, I'll ditch it to reduce > patch size while not introducing any functional change. But then this return is not even being looked at anywhere :-\ > > Acked-by: Jiri Olsa > > Will keep your ack tho :-) > > - Arnaldo > > > thanks, > > jirka