perf help: Fix a bug during strstart() conversion
authorNamhyung Kim <namhyung@kernel.org>
Tue, 14 Nov 2017 00:15:42 +0000 (09:15 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 25 Feb 2018 10:07:54 +0000 (11:07 +0100)
commit182d948c7ae957a152251d34e66d0e3ee382c197
tree8f0deefcfe7dd85f30f181db37b317afeea23dde
parentbfb3906919d12aabc9d1974bb12c01902f7d2506
perf help: Fix a bug during strstart() conversion

[ Upstream commit af98f2273fd0af31ce327cd1406b67c7be0b6734 ]

The commit 8e99b6d4533c changed prefixcmp() to strstart() but missed to
change the return value in some place.  It makes perf help print
annoying output even for sane config items like below:

  $ perf help
  '.root': unsupported man viewer sub key.
  ...

Reported-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Tested-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Tested-by: Taeung Song <treeze.taeung@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Sihyeon Jang <uneedsihyeon@gmail.com>
Cc: kernel-team@lge.com
Link: http://lkml.kernel.org/r/20171114001542.GA16464@sejong
Fixes: 8e99b6d4533c ("tools include: Adopt strstarts() from the kernel")
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
tools/perf/builtin-help.c