From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756671AbbDVNEh (ORCPT ); Wed, 22 Apr 2015 09:04:37 -0400 Received: from mail-pd0-f171.google.com ([209.85.192.171]:36652 "EHLO mail-pd0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755584AbbDVNEe (ORCPT ); Wed, 22 Apr 2015 09:04:34 -0400 Date: Wed, 22 Apr 2015 22:03:25 +0900 From: Namhyung Kim To: Jiri Olsa Cc: Arnaldo Carvalho de Melo , Ingo Molnar , Peter Zijlstra , LKML , David Ahern Subject: Re: [PATCH 08/10] perf hists browser: Split popup menu actions - part 2 Message-ID: <20150422130325.GA1622@danjae.kornet> References: <1429687101-4360-1-git-send-email-namhyung@kernel.org> <1429687101-4360-9-git-send-email-namhyung@kernel.org> <20150422105409.GA27697@krava.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20150422105409.GA27697@krava.redhat.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Jiri, On Wed, Apr 22, 2015 at 12:54:09PM +0200, Jiri Olsa wrote: > On Wed, Apr 22, 2015 at 04:18:19PM +0900, Namhyung Kim wrote: > > SNIP > > > script_browse(script_opt); > > @@ -1505,17 +1585,74 @@ do_run_script(struct hist_browser *browser __maybe_unused, > > } > > > > static int > > -do_switch_data(struct hist_browser *browser __maybe_unused, int key) > > +add_script_opt(struct hist_browser *browser __maybe_unused, > > + struct popup_action *act, char **optstr, > > + struct thread *thread, struct symbol *sym) > > +{ > > + if (thread) { > > + if (asprintf(optstr, "Run scripts for samples of thread [%s]", > > + thread__comm_str(thread)) < 0) > > + return 0; > > + } else if (sym) { > > .............. && sym->namelen ;-) Ouch! sorry for missing this again. Arnaldo, any chance you can fix this if you're gonna merge it? > > but I think you're right, let's see if there's (sym && !sym->namelen) case, > and fix it at the proper place.. not here Agreed. Thanks, Namhyung