summaryrefslogtreecommitdiff
path: root/tools/perf/util/usage.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2017-06-27 17:49:13 +0300
committerArnaldo Carvalho de Melo <acme@redhat.com>2017-06-27 17:49:13 +0300
commitfef2a735167a827a65bbdf1791abe0dd070ce372 (patch)
treeaf25e9617173b6465eb6c5fd96d39350e9883401 /tools/perf/util/usage.c
parent25ce4bb8c50513e922da2709fedc9db112452fbc (diff)
downloadlinux-fef2a735167a827a65bbdf1791abe0dd070ce372.tar.xz
perf tools: Kill die()
Finally can nuke this function, no more users. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-eivvvzn8ie6w42gy3batxoy7@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/usage.c')
-rw-r--r--tools/perf/util/usage.c22
1 files changed, 0 insertions, 22 deletions
diff --git a/tools/perf/util/usage.c b/tools/perf/util/usage.c
index bf185f28b19e..6cc9d9888ce0 100644
--- a/tools/perf/util/usage.c
+++ b/tools/perf/util/usage.c
@@ -9,25 +9,12 @@
#include "util.h"
#include "debug.h"
-static void report(const char *prefix, const char *err, va_list params)
-{
- char msg[1024];
- vsnprintf(msg, sizeof(msg), err, params);
- fprintf(stderr, " %s%s\n", prefix, msg);
-}
-
static __noreturn void usage_builtin(const char *err)
{
fprintf(stderr, "\n Usage: %s\n", err);
exit(129);
}
-static __noreturn void die_builtin(const char *err, va_list params)
-{
- report(" Fatal: ", err, params);
- exit(128);
-}
-
/* If we are in a dlopen()ed .so write to a global variable would segfault
* (ugh), so keep things static. */
static void (*usage_routine)(const char *err) __noreturn = usage_builtin;
@@ -36,12 +23,3 @@ void usage(const char *err)
{
usage_routine(err);
}
-
-void die(const char *err, ...)
-{
- va_list params;
-
- va_start(params, err);
- die_builtin(err, params);
- va_end(params);
-}