summaryrefslogtreecommitdiffstats
path: root/tools/perf/builtin-probe.c
diff options
context:
space:
mode:
authorKirill A. Shutemov <kirill@shutemov.name>2012-07-24 00:06:54 +0300
committerArnaldo Carvalho de Melo <acme@redhat.com>2012-07-25 11:46:04 -0300
commit4cc49d4dc82a39a542a31c1f51ead08a46fd33f1 (patch)
treed8fbb02c3e31e326b9f4bd63574fac56bb7b2eb3 /tools/perf/builtin-probe.c
parent4a841d650ea435c69e60675537f158a620697290 (diff)
downloadlinux-4cc49d4dc82a39a542a31c1f51ead08a46fd33f1.tar.gz
linux-4cc49d4dc82a39a542a31c1f51ead08a46fd33f1.tar.bz2
linux-4cc49d4dc82a39a542a31c1f51ead08a46fd33f1.zip
perf tools: use XSI-complaint version of strerror_r() instead of GNU-specific
Perf uses GNU-specific version of strerror_r(). The GNU-specific strerror_r() returns a pointer to a string containing the error message. This may be either a pointer to a string that the function stores in buf, or a pointer to some (immutable) static string (in which case buf is unused). In glibc-2.16 GNU version was marked with attribute warn_unused_result. It triggers few warnings in perf: util/target.c: In function ‘perf_target__strerror’: util/target.c:114:13: error: ignoring return value of ‘strerror_r’, declared with attribute warn_unused_result [-Werror=unused-result] ui/browsers/hists.c: In function ‘hist_browser__dump’: ui/browsers/hists.c:981:13: error: ignoring return value of ‘strerror_r’, declared with attribute warn_unused_result [-Werror=unused-result] They are bugs. Let's fix strerror_r() usage. Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name> Acked-by: Ulrich Drepper <drepper@gmail.com> Cc: Ingo Molnar <mingo@kernel.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Ulrich Drepper <drepper@gmail.com> Link: http://lkml.kernel.org/r/20120723210654.GA25248@shutemov.name [ committer note: s/assert/BUG_ON/g ] Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/builtin-probe.c')
0 files changed, 0 insertions, 0 deletions