From: Markus Trippelsdorf Date: Mon, 14 Dec 2015 15:44:03 +0000 (+0100) Subject: perf annotate browser: Fix behaviour of Shift-Tab with nothing focussed X-Git-Tag: v3.2.78~46 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?p=pandora-kernel.git;a=commitdiff_plain;h=cbd183c5139f45cdd308d6088b67093033fc6063;ds=inline perf annotate browser: Fix behaviour of Shift-Tab with nothing focussed commit d4913cbd05bab685e49c8174896e563b2487d054 upstream. The issue was pointed out by gcc-6's -Wmisleading-indentation. Signed-off-by: Markus Trippelsdorf Acked-by: Ingo Molnar Cc: Ben Hutchings Cc: Matt Fleming Cc: Peter Zijlstra Fixes: c97cf42219b7 ("perf top: Live TUI Annotation") Link: http://lkml.kernel.org/r/20151214154403.GB1409@x4 Signed-off-by: Arnaldo Carvalho de Melo [bwh: Backported to 3.2: adjust filename, context] Signed-off-by: Ben Hutchings --- diff --git a/tools/perf/util/ui/browsers/annotate.c b/tools/perf/util/ui/browsers/annotate.c index 0575905d1205..6d7e7ca7c251 100644 --- a/tools/perf/util/ui/browsers/annotate.c +++ b/tools/perf/util/ui/browsers/annotate.c @@ -276,11 +276,11 @@ static int annotate_browser__run(struct annotate_browser *self, int evidx, nd = self->curr_hot; break; case K_UNTAB: - if (nd != NULL) + if (nd != NULL) { nd = rb_next(nd); if (nd == NULL) nd = rb_first(&self->entries); - else + } else nd = self->curr_hot; break; case 'H':