Bug 140224

Summary: xmodmap crashes when reading default Xmodmap
Product: [Fedora] Fedora Reporter: Marcel Kyas <mkyas>
Component: xorg-x11Assignee: X/OpenGL Maintenance List <xgl-maint>
Status: CLOSED DUPLICATE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 3   
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-02-21 19:07:12 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Marcel Kyas 2004-11-21 10:57:30 UTC
Description of problem:

xmodmap crashes with segmentation fault when reading /etc/X11/Xmodmap

Version-Release number of selected component (if applicable):

6.8.1

How reproducible:

xmodmap /etc/X11/Xmodmap

Steps to Reproduce:
1.
2.
3.
  
Actual results:

Segmentation violation

Expected results:

It terminates normally


Additional info:

I also filed the bug upstream at
https://bugs.freedesktop.org/show_bug.cgi?id=1875

Comment 1 Martin Blom 2004-11-22 16:21:13 UTC
I'm not sure, but I don't think this happened before the upgrade to
xorg-x11-6.8.1-12.FC3.1.

Also the Layout Options in gnome-keyboard-properties seem to have no
effect anymore after upgrading. Could it be related or should I file a
new bug?

Comment 2 Marcel Kyas 2004-11-22 17:57:06 UTC
Running xmodmap through valgrind gives me
==3561== 26 errors in context 1 of 1:
==3561== Invalid write of size 1
==3561==    at 0x1B902440: strcpy (mac_replace_strmem.c:199)
==3561==    by 0x8049675: (within /usr/X11R6/bin/xmodmap)
==3561==    by 0x804977F: (within /usr/X11R6/bin/xmodmap)
==3561==    by 0x8049155: (within /usr/X11R6/bin/xmodmap)
==3561==  Address 0x1B92A63B is 0 bytes after a block of size 19 alloc'd
==3561==    at 0x1B902A90: malloc (vg_replace_malloc.c:131)
==3561==    by 0x8048FD0: (within /usr/X11R6/bin/xmodmap)
==3561==    by 0x8049664: (within /usr/X11R6/bin/xmodmap)
==3561==    by 0x804977F: (within /usr/X11R6/bin/xmodmap)

I guess there is some off-by-one error in xmodmap.  Also, if I remove
all comments from the file, the crash is not triggered.  I hope this
helps to narrow it down.

Comment 3 Mike A. Harris 2004-11-22 20:53:32 UTC

*** This bug has been marked as a duplicate of 138458 ***

Comment 4 Red Hat Bugzilla 2006-02-21 19:07:12 UTC
Changed to 'CLOSED' state since 'RESOLVED' has been deprecated.