Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 38232 - Quoted expressions in Xservers confuses xdm
Summary: Quoted expressions in Xservers confuses xdm
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High minor (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-01-14 16:36 UTC by Jim Farrand
Modified: 2004-07-08 02:52 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch (for both 430 and 4399 (4152_all_4.3.0-allow-xdm-server-quotes.patch,1.55 KB, patch)
2004-03-02 04:30 UTC, Andrew Bevitt
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jim Farrand 2004-01-14 16:36:42 UTC
Quoted expressions in /etc/X11/xdm/Xservers are not used correctly when starting X.

For example:

:2 local /usr/X11R6/bin/X :2 vt10 -layout "Small Layout"

When X is called, the quoted expression after -layout is passed as two seperate arguments, instead of one as is customary.  (I.e. the arguments '"Small' and 'Layout"' are passed to X, instead of '"Small Layout"' as intended.)

I tried to work around this by escaping the quote characters with a backslash (\"Small Layout\") but this doesn't help.


Reproducible: Always
Steps to Reproduce:
1. Add the line mentioned above to /etc/X11/xdm/Xservers
2. Copy and paste your default layout in /etc/X11/XF86Config and change the identifier to "Small Layout".
3. /etc/init.d/xdm restart

Actual Results:  
1. A second Xserver is NOT started on vt10 as intended.
2. An error message can be seen in /var/log/xdm.log

Expected Results:  
Started a second Xserver on vt10 using the "Small Layout" configuration from
/etc/X11/XF86Config instead of the default layout.

In this case, the bug can be worked around by editing /etc/X11/XF86Config and
/etc/X11/xdm/Xservers to remove spaces from any identifiers you may want to use,
although there may be examples of sitations I have not forseen where passing
quoted expressions cannot be avoided.
Comment 1 Andrew Bevitt 2004-01-17 05:09:10 UTC
I cannot reproduce this, ive got a few X versions compiled currently 
and none seem to exhibit this behaviour...?

What version of X was this on? Can you try the latest 4.3.0 ebuild 
(and if at all possible 4.3.99.902) and see if the problem still 
persists.

The default name of the layout from xf86config is "Simple Layout"
so im quite surprised that you are experiencing this difficulty.
Comment 2 Jim Farrand 2004-01-17 08:55:47 UTC
This is with xfree-4.3.0-r3.  Note that the fact that the default in /etc/X11/XF86Config is "Simple Layout" is not relevant, because the default /etc/X11/xdm/Xservers does not specify a layout, it just runs X without any parameters.

Just to be sure we are clear what is happening, the problem is NOT with quoted expressions in /etc/X11/XF86Config, but rather with quoted expressions in 
/etc/X11/xdm/Xservers.

I can try 4.3.99.902 but probably not until next weekend.
Comment 3 Andrew Bevitt 2004-01-18 22:04:41 UTC
OK I had another look at this now using xdm and indeed it does occur.
(I wasnt xdm-ing before)

There are several things that im looking at in relation to this. The X initaliser itself maybe responsible, but that does not appear to be the case when you issue similar commands from the console, so im a little confused there. Im thinking perhaps that xdm gets confused on the "'s or doesnt recognise them at all... 

Researching some more 
Comment 4 Andrew Bevitt 2004-03-02 04:30:52 UTC
Created attachment 26708 [details, diff]
Patch (for both 430 and 4399

OK this patch applies cleanly here to both 4.3.0 and 4.3.99.* as we do not as
yet patch xdm/file.c and it appears that this file hasnt been edited in a
while... 

This is a bit dirty, there probably are better ways look in
xc/programs/Xserver/hw/xfree86/common/scan.c for ideas if you are interested,
but this way will achieve what is necessary.
Comment 5 Donnie Berkholz (RETIRED) gentoo-dev 2004-03-17 11:35:33 UTC
Fixed in 4.3.0-r6.
Comment 6 Donnie Berkholz (RETIRED) gentoo-dev 2004-07-08 02:52:20 UTC
Also fixed in xorg-x11-6.7.0-r1.