From 32b2b6ec57a3adb3ab7215fbf36ec61c15de06ee Mon Sep 17 00:00:00 2001 From: Franck Bui-Huu Date: Wed, 22 Dec 2010 17:37:13 +0100 Subject: perf probe: Fix wrong warning in __show_one_line() if read(1) errors happen This was introduced by commit fde52dbd7f71934aba4e150f3d1d51e826a08850. Cc: H. Peter Anvin Cc: Masami Hiramatsu Cc: Ingo Molnar Cc: Thomas Gleixner LKML-Reference: Signed-off-by: Franck Bui-Huu Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/util/probe-event.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tools') diff --git a/tools/perf/util/probe-event.c b/tools/perf/util/probe-event.c index 099336ed34b4..4bde988a0b04 100644 --- a/tools/perf/util/probe-event.c +++ b/tools/perf/util/probe-event.c @@ -309,7 +309,7 @@ static int __show_one_line(FILE *fp, int l, bool skip, bool show_num) return 1; error: if (ferror(fp)) { - pr_warning("Source file is shorter than expected.\n"); + pr_warning("File read error: %s\n", strerror(errno)); return -1; } return 0; -- cgit v1.2.1