Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756241AbYBESFY (ORCPT ); Tue, 5 Feb 2008 13:05:24 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752077AbYBESFM (ORCPT ); Tue, 5 Feb 2008 13:05:12 -0500 Received: from gprs189-60.eurotel.cz ([160.218.189.60]:60904 "EHLO amd.ucw.cz" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751756AbYBESFL (ORCPT ); Tue, 5 Feb 2008 13:05:11 -0500 Date: Tue, 5 Feb 2008 19:05:19 +0100 From: Pavel Machek To: Jiri Kosina Cc: kernel list , Ingo Molnar , Abel Bernabeu , Hugh Dickins , Arjan van de Ven Subject: Re: brk randomization breaks columns Message-ID: <20080205180519.GA1525@elf.ucw.cz> References: <20080204122837.GA1647@elf.ucw.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Warning: Reading this can be dangerous to your mental health. User-Agent: Mutt/1.5.17 (2007-11-01) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1200 Lines: 39 Hi! > diff --git a/mm/mmap.c b/mm/mmap.c > index 8295577..1c3b48f 100644 > --- a/mm/mmap.c > +++ b/mm/mmap.c > @@ -241,7 +241,7 @@ asmlinkage unsigned long sys_brk(unsigned long brk) > > down_write(&mm->mmap_sem); > > - if (brk < mm->end_code) > + if (brk < mm->start_brk) > goto out; > > /* Sorry, I now tested the patch. It looked good to my untrained eyes, but upon testing it on columns: ... personality(PER_LINUX) = 4194304 geteuid() = 1000 getuid() = 1000 getgid() = 1002 getegid() = 1002 brk(0x8054098) = 0x922d000 --- SIGSEGV (Segmentation fault) @ 0 (0) --- ...it should have said -EINVAL or something like that. Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/