[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#277884: xserver-xfree86: X segfaults on AMD64 with noexec enabled



On Fri, Feb 04, 2005 at 06:28:11PM +0000, Piotr Kaczuba wrote:
> I have been experiencing the same problem with xserver 4.3.0.dfsg.1-10,  
> even with noexec=off. The symptoms were signal 11 on first xfree module  
> load and strace showing that mprotect failed with EINVAL.
> The problem was that the address passed to mprotect wasn't aligned to  
> the pagesize (4096). I've searched on google and found a rather old  
> patch from Redhat that solves the error.
> I've applied the attached patch on top of all the other ones from  
> 4.3.0.dfsg.1-10 source and X is now running fine.
> 
> Just saw that I've deleted the patch tailored for debian, so attached  
> is the original one from Redhat. The linux defines are already present  
> in debian, so you only need the mprotect part.

Thanks, Piotr!  I am applying this patch; you can expect it to be in the
next release.

I notice that the page-alignment patch is algorithmically the same as code
that was already present in the other use of mprotect() in elfloader.c;
that it wasn't updated indicates that someone was careless when hacking on
this file in the past.

Thanks again.

-- 
G. Branden Robinson                |    Half of being smart is knowing what
Debian GNU/Linux                   |    you're dumb at.
branden@debian.org                 |    -- David Gerrold
http://people.debian.org/~branden/ |

Attachment: signature.asc
Description: Digital signature


Reply to: