From: David Ahern <dsahern@gmail.com>
To: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>,
Namhyung Kim <namhyung@kernel.org>
Cc: Minchan Kim <minchan@kernel.org>,
Peter Zijlstra <a.p.zijlstra@chello.nl>,
Ingo Molnar <mingo@kernel.org>, Paul Mackerras <paulus@samba.org>,
Namhyung Kim <namhyung.kim@lge.com>,
LKML <linux-kernel@vger.kernel.org>, Jiri Olsa <jolsa@redhat.com>
Subject: Re: [PATCH 1/2] perf tools: Ensure --symfs ends with '/'
Date: Wed, 30 Jul 2014 16:20:43 -0600 [thread overview]
Message-ID: <53D96FBB.4010907@gmail.com> (raw)
In-Reply-To: <20140730205521.GU7831@kernel.org>
On 7/30/14, 2:55 PM, Arnaldo Carvalho de Melo wrote:
> @@ -143,6 +144,14 @@ struct symbol_conf {
> };
>
> extern struct symbol_conf symbol_conf;
> +
> +static inline int __symbol__join_symfs(char *bf, size_t size, const char *path)
> +{
> + return path__join(bf, size, symbol_conf.symfs, path);
> +}
> +
> +#define symbol__join_symfs(bf, path) __symbol__join_symfs(bf, sizeof(bf), path)
> +
> extern int vmlinux_path__nr_entries;
> extern char **vmlinux_path;
>
I am not comfortable with the sizeof(bf) in the macro there. It is to a
large degree hiding an important detail and sets up odd failures in the
future. ie., It works fine for 'char bf[N];' but not for 'char *bf =
"some string";'.
David
next prev parent reply other threads:[~2014-07-30 22:20 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-25 1:31 [PATCH 1/2] perf tools: Ensure --symfs ends with '/' Namhyung Kim
2014-07-25 1:31 ` [PATCH 2/2] perf tools: Check validity of --symfs value Namhyung Kim
2014-07-25 13:15 ` [PATCH 1/2] perf tools: Ensure --symfs ends with '/' Arnaldo Carvalho de Melo
2014-07-28 1:04 ` Namhyung Kim
2014-07-29 5:02 ` Minchan Kim
2014-07-29 12:33 ` Arnaldo Carvalho de Melo
2014-07-29 13:26 ` Minchan Kim
2014-07-29 13:43 ` Arnaldo Carvalho de Melo
2014-07-29 15:12 ` Arnaldo Carvalho de Melo
2014-07-29 13:57 ` David Ahern
2014-07-29 23:52 ` Namhyung Kim
2014-07-30 15:19 ` Arnaldo Carvalho de Melo
2014-07-30 20:55 ` Arnaldo Carvalho de Melo
2014-07-30 22:20 ` David Ahern [this message]
2014-07-31 4:25 ` Namhyung Kim
2014-07-31 12:26 ` Arnaldo Carvalho de Melo
2014-07-31 23:38 ` Namhyung Kim
2014-08-01 20:15 ` Arnaldo Carvalho de Melo
2014-08-11 7:38 ` Namhyung Kim
2014-08-11 13:15 ` Arnaldo Carvalho de Melo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53D96FBB.4010907@gmail.com \
--to=dsahern@gmail.com \
--cc=a.p.zijlstra@chello.nl \
--cc=acme@ghostprotocols.net \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=minchan@kernel.org \
--cc=mingo@kernel.org \
--cc=namhyung.kim@lge.com \
--cc=namhyung@kernel.org \
--cc=paulus@samba.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).