xvfb-run munges stdout and stderr together

Bug #1059947 reported by Robert Collins on 2012-10-02
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
xorg-server (Ubuntu)
Undecided
Unassigned

Bug Description

It executes the supplied command thusly:
DISPLAY=:$SERVERNUM XAUTHORITY=$AUTHFILE "$@" 2>&1

This should be
DISPLAY=:$SERVERNUM XAUTHORITY=$AUTHFILE "$@"

Leaving the caller to redirect stderr to stdout, or to supply a single fd at their discretion. The side effect of munging the two fd's together is that programs which provide structured data on stdout have their output streams corrupted if they, or any subprocesses they have, happen to write to stderr at an inopportune time.

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in xorg-server (Ubuntu):
status: New → Confirmed
Leon Blakey (thelq) wrote :

Any updates? This still exists 4 years later in xvfb 2:1.16.4-1 . The only workaround is to copy the entire script locally and remove those 4 characters.

Also the package is xvfb, not xorg-server

Timo Aaltonen (tjaalton) wrote :

the source package is xorg-server

changing this would break a ton of autopkgtests that use xvfb-run which now get errors like:

testsuite FAIL stderr: QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to
             '/tmp/runtime-ubuntu'

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package xorg-server - 2:1.19.4-1ubuntu2

---------------
xorg-server (2:1.19.4-1ubuntu2) artful; urgency=medium

  * xvfb-run: Keep redirecting stderr to stdout, autopkgtests need it.

 -- Timo Aaltonen <email address hidden> Wed, 11 Oct 2017 11:12:57 +0300

Changed in xorg-server (Ubuntu):
status: Confirmed → Fix Released
Timo Aaltonen (tjaalton) on 2017-10-12
Changed in xorg-server (Ubuntu):
status: Fix Released → Triaged
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers