From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751164AbdALNcE (ORCPT ); Thu, 12 Jan 2017 08:32:04 -0500 Received: from mail.kernel.org ([198.145.29.136]:53126 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750879AbdALNcC (ORCPT ); Thu, 12 Jan 2017 08:32:02 -0500 Date: Thu, 12 Jan 2017 10:31:57 -0300 From: Arnaldo Carvalho de Melo To: Jiri Olsa Cc: 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: <20170112133157.GA20003@kernel.org> References: <20170103150833.6694-1-andi@firstfloor.org> <20170103150833.6694-2-andi@firstfloor.org> <20170108185753.GC14072@krava> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170108185753.GC14072@krava> 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 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. > Acked-by: Jiri Olsa Will keep your ack tho :-) - Arnaldo > thanks, > jirka