From 3141c8b165644774eb0e83d8330fbe47e45b37bf Mon Sep 17 00:00:00 2001 From: Jiri Slaby Date: Tue, 26 Jul 2011 16:08:32 -0700 Subject: coredump: use task comm instead of (unknown) If we don't know the file corresponding to the binary (i.e. exe_file is unknown), use "task->comm (path unknown)" instead of simple "(unknown)" as suggested by ak. The fallback is the same as %e except it will append "(path unknown)". Signed-off-by: Jiri Slaby Cc: Alan Cox Cc: Al Viro Cc: Andi Kleen Cc: Oleg Nesterov Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- fs/exec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'fs/exec.c') diff --git a/fs/exec.c b/fs/exec.c index 842d570..a682624 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -1657,7 +1657,7 @@ static int cn_print_exe_file(struct core_name *cn) exe_file = get_mm_exe_file(current->mm); if (!exe_file) - return cn_printf(cn, "(unknown)"); + return cn_printf(cn, "%s (path unknown)", current->comm); pathbuf = kmalloc(PATH_MAX, GFP_TEMPORARY); if (!pathbuf) { -- cgit v1.1