diff options
author | Jiri Olsa <jolsa@redhat.com> | 2014-04-16 14:49:02 -0400 |
---|---|---|
committer | Jiri Olsa <jolsa@redhat.com> | 2014-04-22 11:39:09 -0400 |
commit | 7c2f8164e5415ef48954f6929f4acae5764afdb4 (patch) | |
tree | 3abc7efe2220ce6412a9b281c06894442375404c /tools/perf | |
parent | 4a3dc121d3c370625575247bf714db3f601d83e9 (diff) |
perf tools: Fix pmu object compilation error
After applying some patches got another shadowing error:
CC util/pmu.o
util/pmu.c: In function ‘pmu_alias_terms’:
util/pmu.c:287:35: error: declaration of ‘clone’ shadows a global declaration [-Werror=shadow]
Renaming clone to cloned.
Acked-by: David Ahern <dsahern@gmail.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Link: http://lkml.kernel.org/r/1397674818-27054-1-git-send-email-jolsa@redhat.com
Signed-off-by: Jiri Olsa <jolsa@redhat.com>
Diffstat (limited to 'tools/perf')
-rw-r--r-- | tools/perf/util/pmu.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/perf/util/pmu.c b/tools/perf/util/pmu.c index 00a7dcb2f55c..7a811eb61f75 100644 --- a/tools/perf/util/pmu.c +++ b/tools/perf/util/pmu.c | |||
@@ -284,17 +284,17 @@ static int pmu_aliases(const char *name, struct list_head *head) | |||
284 | static int pmu_alias_terms(struct perf_pmu_alias *alias, | 284 | static int pmu_alias_terms(struct perf_pmu_alias *alias, |
285 | struct list_head *terms) | 285 | struct list_head *terms) |
286 | { | 286 | { |
287 | struct parse_events_term *term, *clone; | 287 | struct parse_events_term *term, *cloned; |
288 | LIST_HEAD(list); | 288 | LIST_HEAD(list); |
289 | int ret; | 289 | int ret; |
290 | 290 | ||
291 | list_for_each_entry(term, &alias->terms, list) { | 291 | list_for_each_entry(term, &alias->terms, list) { |
292 | ret = parse_events_term__clone(&clone, term); | 292 | ret = parse_events_term__clone(&cloned, term); |
293 | if (ret) { | 293 | if (ret) { |
294 | parse_events__free_terms(&list); | 294 | parse_events__free_terms(&list); |
295 | return ret; | 295 | return ret; |
296 | } | 296 | } |
297 | list_add_tail(&clone->list, &list); | 297 | list_add_tail(&cloned->list, &list); |
298 | } | 298 | } |
299 | list_splice(&list, terms); | 299 | list_splice(&list, terms); |
300 | return 0; | 300 | return 0; |