From owner-freebsd-bugs@FreeBSD.ORG Thu Jan 31 13:00:06 2008 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7AD3C16A4A0 for ; Thu, 31 Jan 2008 13:00:06 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 5697413C448 for ; Thu, 31 Jan 2008 13:00:06 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.2/8.14.2) with ESMTP id m0VD05sU073659 for ; Thu, 31 Jan 2008 13:00:05 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id m0VD05DZ073658; Thu, 31 Jan 2008 13:00:05 GMT (envelope-from gnats) Date: Thu, 31 Jan 2008 13:00:05 GMT Message-Id: <200801311300.m0VD05DZ073658@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Jaakko Heinonen Cc: Subject: Re: bin/120055: [linux] kdump(1) segfaults on freebsd6_mmap syscall X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Jaakko Heinonen List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 31 Jan 2008 13:00:06 -0000 The following reply was made to PR bin/120055; it has been noted by GNATS. From: Jaakko Heinonen To: bug-followup@FreeBSD.org, patpr@davenulle.org Cc: Subject: Re: bin/120055: [linux] kdump(1) segfaults on freebsd6_mmap syscall Date: Thu, 31 Jan 2008 14:57:19 +0200 --6TrnltStXW4iwmi0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline This is a duplicate of kern/119564. (You should use devel/linux_kdump port for Linux binaries.) However I think that it might be reasonable to commit the attached patch to avoid kdump segfaulting on "corrupted" dumps. --6TrnltStXW4iwmi0 Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="kdump_segfault.diff" Index: kdump.c =================================================================== RCS file: /home/ncvs/src/usr.bin/kdump/kdump.c,v retrieving revision 1.39 diff -u -r1.39 kdump.c --- kdump.c 7 Jan 2008 18:50:25 -0000 1.39 +++ kdump.c 31 Jan 2008 12:46:35 -0000 @@ -770,7 +770,7 @@ narg--; } } - while (narg) { + while (narg > 0) { print_number(ip,narg,c); } (void)putchar(')'); --6TrnltStXW4iwmi0--