From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752076AbcAGIBK (ORCPT ); Thu, 7 Jan 2016 03:01:10 -0500 Received: from LGEAMRELO11.lge.com ([156.147.23.51]:58158 "EHLO lgeamrelo11.lge.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750827AbcAGIBI (ORCPT ); Thu, 7 Jan 2016 03:01:08 -0500 X-Original-SENDERIP: 156.147.1.151 X-Original-MAILFROM: namhyung@kernel.org X-Original-SENDERIP: 165.244.98.150 X-Original-MAILFROM: namhyung@kernel.org X-Original-SENDERIP: 10.177.227.17 X-Original-MAILFROM: namhyung@kernel.org Date: Thu, 7 Jan 2016 17:01:04 +0900 From: Namhyung Kim To: Taeung Song CC: Arnaldo Carvalho de Melo , linux-kernel@vger.kernel.org, Ingo Molnar , Jiri Olsa Subject: Re: [PATCH RESEND] perf tools: bug fix, an error of parsing 'man..*' config variable. Message-ID: <20160107080104.GH8053@sejong> References: <1452139251-23725-1-git-send-email-treeze.taeung@gmail.com> MIME-Version: 1.0 In-Reply-To: <1452139251-23725-1-git-send-email-treeze.taeung@gmail.com> User-Agent: Mutt/1.5.24 (2015-08-30) X-MIMETrack: Itemize by SMTP Server on LGEKRMHUB04/LGE/LG Group(Release 8.5.3FP6|November 21, 2013) at 2016/01/07 17:01:05, Serialize by Router on LGEKRMHUB04/LGE/LG Group(Release 8.5.3FP6|November 21, 2013) at 2016/01/07 17:01:05, Serialize complete at 2016/01/07 17:01:05 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Taeung, On Thu, Jan 07, 2016 at 01:00:51PM +0900, Taeung Song wrote: > To add new man viewer, configs like 'man..cmd', > 'man..path' can be set into config file (~/.perfconfig). > But parsing config file is stopped because the config variable > contains '.' character i.e. > > If setting 'man.xman.cmd' into config file, > > [man] > gman.cmd = gman > > when launching perf an error message is printed like below. > > Fatal: bad config file line 11 in /home/taeung/.perfconfig Not sure anyone actually uses this.. Anyway, it should be fixed since man viewer code requires it. > > So modify iskeychar() function to decide '.' character > as key character parsing config file. > > Cc: Jiri Olsa > Signed-off-by: Taeung Song Acked-by: Namhyung Kim Thanks, Namhyung > --- > tools/perf/util/config.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tools/perf/util/config.c b/tools/perf/util/config.c > index d3e12e3..3c01ced 100644 > --- a/tools/perf/util/config.c > +++ b/tools/perf/util/config.c > @@ -122,7 +122,7 @@ static char *parse_value(void) > > static inline int iskeychar(int c) > { > - return isalnum(c) || c == '-' || c == '_'; > + return isalnum(c) || c == '-' || c == '_' || c == '.'; > } > > static int get_value(config_fn_t fn, void *data, char *name, unsigned int len) > -- > 2.5.0 >