Date: Mon, 20 Aug 2007 07:10:47 +0400 From: Andrey Chernov <ache@nagual.pp.ru> To: Rong-en Fan <grafan@gmail.com> Cc: ports@freebsd.org Subject: Re: 'dialog' core dump fix [patch for approvement] Message-ID: <20070820031047.GA32404@nagual.pp.ru> In-Reply-To: <6eb82e0708191840n2d2d179dw9779120d4319b064@mail.gmail.com> References: <20070819204509.GA22579@nagual.pp.ru> <6eb82e0708191840n2d2d179dw9779120d4319b064@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Aug 20, 2007 at 09:40:08AM +0800, Rong-en Fan wrote: > On 8/20/07, Andrey Chernov <ache@nagual.pp.ru> wrote: > > It fix dialog core dump with recent ghostscript-gpl port (too many items). > > Please approve. > > Could you tell more about this core dump? I haven't experienced this > when upgrading gs-gpl on all my boxes, including i386 and amd64 6.x > system. unsigned char result[MAX_LEN]; ... retval = dialog_checklist(title, argv[offset+2], atoi(argv[offset+3]), atoi(argv[offset+4]), atoi(argv[offset+5]), (argc-offset-6)/3, argv+offset + 6, result); "result" is overflowing (check the sum of tempfile strings lengths in the scripts/configure) But core dump happens not here immediately, it happens in the strange place - in the return from main() :-) (because the stack is corrupted) ... EndDialog(clear_screen); return retval; ^ here -- http://ache.pp.ru/
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070820031047.GA32404>