aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tools/perf/builtin-trace.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/perf/builtin-trace.c b/tools/perf/builtin-trace.c
index c70e69ea1c5d..09bcf2393910 100644
--- a/tools/perf/builtin-trace.c
+++ b/tools/perf/builtin-trace.c
@@ -1695,7 +1695,7 @@ static int trace__sys_exit(struct trace *trace, struct perf_evsel *evsel,
1695 union perf_event *event __maybe_unused, 1695 union perf_event *event __maybe_unused,
1696 struct perf_sample *sample) 1696 struct perf_sample *sample)
1697{ 1697{
1698 int ret; 1698 long ret;
1699 u64 duration = 0; 1699 u64 duration = 0;
1700 struct thread *thread; 1700 struct thread *thread;
1701 int id = perf_evsel__sc_tp_uint(evsel, id, sample); 1701 int id = perf_evsel__sc_tp_uint(evsel, id, sample);
@@ -1748,7 +1748,7 @@ static int trace__sys_exit(struct trace *trace, struct perf_evsel *evsel,
1748 1748
1749 if (sc->fmt == NULL) { 1749 if (sc->fmt == NULL) {
1750signed_print: 1750signed_print:
1751 fprintf(trace->output, ") = %d", ret); 1751 fprintf(trace->output, ") = %ld", ret);
1752 } else if (ret < 0 && sc->fmt->errmsg) { 1752 } else if (ret < 0 && sc->fmt->errmsg) {
1753 char bf[STRERR_BUFSIZE]; 1753 char bf[STRERR_BUFSIZE];
1754 const char *emsg = strerror_r(-ret, bf, sizeof(bf)), 1754 const char *emsg = strerror_r(-ret, bf, sizeof(bf)),
@@ -1758,7 +1758,7 @@ signed_print:
1758 } else if (ret == 0 && sc->fmt->timeout) 1758 } else if (ret == 0 && sc->fmt->timeout)
1759 fprintf(trace->output, ") = 0 Timeout"); 1759 fprintf(trace->output, ") = 0 Timeout");
1760 else if (sc->fmt->hexret) 1760 else if (sc->fmt->hexret)
1761 fprintf(trace->output, ") = %#x", ret); 1761 fprintf(trace->output, ") = %#lx", ret);
1762 else 1762 else
1763 goto signed_print; 1763 goto signed_print;
1764 1764