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>
This commit is contained in:
parent
4a3dc121d3
commit
7c2f8164e5
1 changed files with 3 additions and 3 deletions
|
@ -284,17 +284,17 @@ static int pmu_aliases(const char *name, struct list_head *head)
|
||||||
static int pmu_alias_terms(struct perf_pmu_alias *alias,
|
static int pmu_alias_terms(struct perf_pmu_alias *alias,
|
||||||
struct list_head *terms)
|
struct list_head *terms)
|
||||||
{
|
{
|
||||||
struct parse_events_term *term, *clone;
|
struct parse_events_term *term, *cloned;
|
||||||
LIST_HEAD(list);
|
LIST_HEAD(list);
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
list_for_each_entry(term, &alias->terms, list) {
|
list_for_each_entry(term, &alias->terms, list) {
|
||||||
ret = parse_events_term__clone(&clone, term);
|
ret = parse_events_term__clone(&cloned, term);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
parse_events__free_terms(&list);
|
parse_events__free_terms(&list);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
list_add_tail(&clone->list, &list);
|
list_add_tail(&cloned->list, &list);
|
||||||
}
|
}
|
||||||
list_splice(&list, terms);
|
list_splice(&list, terms);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue