[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <54F049BB.1000506@hitachi.com>
Date: Fri, 27 Feb 2015 19:40:59 +0900
From: Masami Hiramatsu <masami.hiramatsu.pt@...achi.com>
To: He Kuang <hekuang@...wei.com>
Cc: acme@...nel.org, mingo@...hat.com, wangnan0@...wei.com,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] perf: Fix a precedence bug
Hi,
(2015/02/27 18:35), He Kuang wrote:
> The minus operator has higher precedence than ?:
> Add parentheses around ?: fix this.
Thank you for fixing that,
Could you give us an actual example of the result?
e.g. What happened? and how to reproduce it?
Thank you,
> ---
> tools/perf/util/probe-event.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tools/perf/util/probe-event.c b/tools/perf/util/probe-event.c
> index 919937e..bed8d0f 100644
> --- a/tools/perf/util/probe-event.c
> +++ b/tools/perf/util/probe-event.c
> @@ -150,7 +150,7 @@ static u64 kernel_get_symbol_address_by_name(const char *name, bool reloc)
> sym = __find_kernel_function_by_name(name, &map);
> if (sym)
> return map->unmap_ip(map, sym->start) -
> - (reloc) ? 0 : map->reloc;
> + ((reloc) ? 0 : map->reloc);
> }
> return 0;
> }
>
--
Masami HIRAMATSU
Software Platform Research Dept. Linux Technology Research Center
Hitachi, Ltd., Yokohama Research Laboratory
E-mail: masami.hiramatsu.pt@...achi.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists