Please sign in to comment.
perf tools: Use scnprintf where applicable
commit e7f01d1 upstream. Several places were expecting that the value returned was the number of characters printed, not what would be printed if there was space. Fix it by using the scnprintf and vscnprintf variants we inherited from the kernel sources. Some corner cases where the number of printed characters were not accounted were fixed too. Reported-by: Anton Blanchard <email@example.com> Cc: Anton Blanchard <firstname.lastname@example.org> Cc: Eric B Munson <email@example.com> Cc: David Ahern <firstname.lastname@example.org> Cc: Frederic Weisbecker <email@example.com> Cc: Mike Galbraith <firstname.lastname@example.org> Cc: Paul Mackerras <email@example.com> Cc: Peter Zijlstra <firstname.lastname@example.org> Cc: Stephane Eranian <email@example.com> Cc: Yanmin Zhang <firstname.lastname@example.org> Link: http://email@example.com Signed-off-by: Arnaldo Carvalho de Melo <firstname.lastname@example.org> Signed-off-by: Greg Kroah-Hartman <email@example.com>
- Loading branch information...
Showing with 35 additions and 33 deletions.
- +1 −1 tools/perf/arch/powerpc/util/header.c
- +1 −1 tools/perf/arch/x86/util/header.c
- +5 −4 tools/perf/util/color.c
- +2 −2 tools/perf/util/header.c
- +15 −15 tools/perf/util/hist.c
- +4 −3 tools/perf/util/strbuf.c
- +6 −6 tools/perf/util/ui/browsers/hists.c
- +1 −1 tools/perf/util/ui/helpline.c