Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 347758

Summary: x11-apps/xrdb-1.0.7 ignores continuation lines; runtime error with GCC 4.5
Product: Gentoo Linux Reporter: Ulrich Müller <ulm>
Component: Current packagesAssignee: Gentoo X packagers <x11>
Severity: major    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 296658    
Attachments: Proposed patch for xrdb.c

Description Ulrich Müller gentoo-dev 2010-12-04 20:10:00 UTC
I've the following in my .Xdefaults (unchanged since a long time):

    *VT100.Translations: #override \
        <Key>BackSpace: string(0x7F)\n\
        <Key>Delete:    string("\033[3~")

With xrdb-1.0.7 and gcc-4.5.1, the backslash for line continuation doesn't work any more. xrdb -q shows that each of the above lines will end up in an own resource:

*VT100.Translations:    #override
<Key>BackSpace: string(0x7F)\n
<Key>Delete:    string("\033[3~")

Whereas with gcc-4.4.5 everything is as it should be:

*VT100.Translations: #override    <Key>BackSpace: string(0x7F)\n    <Key>Delete: string("\033[3~")

The problem depends only on the gcc version selected at run time. It doesn't matter if xrdb is compiled with gcc 4.4 or 4.5.

My guess is that it's caused by this change of C preprocessor behaviour: <>
So adding option -P or -traditional-cpp to the cpp call should fix the problem.

See also OpenSuSE bug <>.
Comment 1 Ulrich Müller gentoo-dev 2010-12-11 19:55:48 UTC
Created attachment 256924 [details, diff]
Proposed patch for xrdb.c

Attached patch fixes the problem for me.
Comment 2 Helmut Jarausch 2010-12-28 12:14:55 UTC
(In reply to comment #1)
> Created an attachment (id=256924) [details]
> Proposed patch for xrdb.c
> Attached patch fixes the problem for me.

I've been looking around for some problems with X-applications which have failed
recently. Your patch fixes these.

Please raise the priority since this is a very ugly bug which should be fixed ASAP.
Comment 3 Chí-Thanh Christopher Nguyễn gentoo-dev 2010-12-28 12:37:40 UTC
What is the upstream status of this?

x11 team generally is reluctant to take patches which upstream has not even commented on.
Comment 4 Ulrich Müller gentoo-dev 2010-12-28 15:19:18 UTC
(In reply to comment #3)
> What is the upstream status of this?

Is the right location to report this?

(I hadn't contacted upstream, because I had assumed that the OpenSuSE folks would forward their identical issue.)
Comment 5 Chí-Thanh Christopher Nguyễn gentoo-dev 2010-12-28 15:34:25 UTC
Yes, report a bug at and if possible, please also send a git formatted patch to
Comment 6 Ulrich Müller gentoo-dev 2010-12-28 15:39:35 UTC
Reported upstream, see <>.
Comment 7 Ulrich Müller gentoo-dev 2011-01-08 15:50:39 UTC
Created attachment 259295 [details, diff]

A modified patch has been applied upstream: <>

Upstream has rebased my patch though and it can't be used for xrdb-1.0.7 any more.
Attached is the patch that I had originally sent and which cleanly applies to 1.0.7.
Comment 8 Ulrich Müller gentoo-dev 2011-02-15 21:06:36 UTC
This is fixed in xrdb-1.0.8. Therefore closing.