[Xfce-bugs] [Bug 10828] New: [Patch] Non-POSIX compliant test used in startxfce4 (uses #!/bin/sh), prevents --help and other args on some shells
bugzilla-daemon at xfce.org
bugzilla-daemon at xfce.org
Fri Apr 18 01:54:23 CEST 2014
https://bugzilla.xfce.org/show_bug.cgi?id=10828
Bug ID: 10828
Summary: [Patch] Non-POSIX compliant test used in startxfce4
(uses #!/bin/sh), prevents --help and other args on
some shells
Classification: Xfce
Product: Xfce4-session
Version: Unspecified
Hardware: All
OS: Linux
Status: NEW
Severity: normal
Priority: Medium
Component: General
Assignee: xfce-bugs at xfce.org
Reporter: seejay.11 at gmail.com
QA Contact: bjt23 at cornell.edu
CC: benny at xfce.org, nick at xfce.org
Created attachment 5438
--> https://bugzilla.xfce.org/attachment.cgi?id=5438&action=edit
patch generated by git diff
The command line arguments "--help" and "--with-ck-launch" can't be used on
systems which have a non-bash /bin/sh (e.g. Debian, as far as I'm aware). This
is due to the use of "==" instead of "=" in test commands, which is a bash
extension.
I discovered this with the "checkbashisms" perl script while switching my
/bin/sh from bash to dash on Arch.
To verify (with dash installed):
DISPLAY=invalid # Avoid actually launching xfce; this should prevent it
dash "$(which startxfce4)" --help
It should output usage information, but what it actually outputs is the
following:
/usr/bin/startxfce4: 27: test: x--help: unexpected operator
/usr/bin/startxfce4: 40: test: x--help: unexpected operator
/usr/bin/startxfce4: X server already running on display invalid
xrdb: Can't open display 'invalid'
xfce4-session: Cannot open display: .
Type 'xfce4-session --help' for usage.
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the Xfce-bugs
mailing list