Skip to content

Commit 300d4fe

Browse files
Markus Trippelsdorfgregkh
authored andcommitted
perf pmu: Fix misleadingly indented assignment (whitespace)
commit d85ce830eef6c10d1e9617172dea4681f02b8424 upstream. One line in perf_pmu__parse_unit() is indented wrongly, leading to a warning (=> error) from gcc 6: util/pmu.c:156:3: error: statement is indented as if it were guarded by... [-Werror=misleading-indentation] sret = read(fd, alias->unit, UNIT_MAX_LEN); ^~~~ util/pmu.c:153:2: note: ...this 'if' clause, but it is not if (fd == -1) ^~ Signed-off-by: Markus Trippelsdorf <markus@trippelsdorf.de> Acked-by: Ingo Molnar <mingo@kernel.org> Cc: Ben Hutchings <ben@decadent.org.uk> Cc: Matt Fleming <matt@codeblueprint.co.uk> Cc: Peter Zijlstra <peterz@infradead.org> Fixes: 410136f ("tools/perf/stat: Add event unit and scale support") Link: http://lkml.kernel.org/r/20151214154440.GC1409@x4 Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 0ba2f07 commit 300d4fe

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

tools/perf/util/pmu.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ static int perf_pmu__parse_unit(struct perf_pmu_alias *alias, char *dir, char *n
153153
if (fd == -1)
154154
return -1;
155155

156-
sret = read(fd, alias->unit, UNIT_MAX_LEN);
156+
sret = read(fd, alias->unit, UNIT_MAX_LEN);
157157
if (sret < 0)
158158
goto error;
159159

0 commit comments

Comments
 (0)