Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753852AbbB0Ki3 (ORCPT ); Fri, 27 Feb 2015 05:38:29 -0500 Received: from szxga02-in.huawei.com ([119.145.14.65]:45891 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751348AbbB0Ki0 (ORCPT ); Fri, 27 Feb 2015 05:38:26 -0500 Message-ID: <54F0490B.5090009@huawei.com> Date: Fri, 27 Feb 2015 18:38:03 +0800 From: He Kuang User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.3.0 MIME-Version: 1.0 To: , , CC: , Subject: Re: [PATCH] perf: Fix a precedence bug References: <1425029729-5069-1-git-send-email-hekuang@huawei.com> In-Reply-To: <1425029729-5069-1-git-send-email-hekuang@huawei.com> Content-Type: text/plain; charset="gbk"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.110.54.65] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1011 Lines: 28 Signed-off-by: He Kuang ?? 2015/2/27 17:35, He Kuang ะด??: > The minus operator has higher precedence than ?: > Add parentheses around ?: fix this. > --- > 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; > } -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/