I want to correct myself: When discussing this with more experienced
developers, my attention was called to the fact that I had missed the
distinction between syntax errors and other errors. While a syntax error
kills the process, other errors, e.g. "not found", don't. Hence you can
disregard my talk about the -e option.
A possible solution did come up. Replacing this /etc/gdm/Xsession line:
test -f "$HOME/.profile" && . "$HOME/.profile"
with
test -f "$HOME/.profile" && ( . "$HOME/.profile" ) && .
"$HOME/.profile"
would protect against a ~/.profile syntax error causing the process to
be killed. For two reasons it's not considered appropriate, at least not
as soon before the 11.04 release as we are now:
1. Regression risk due to the ~/.profile commands being run twice (even
if they would be run in a subprocess the first time).
2. Efficiency loss.
For the case the conclusion will change after the 11.04 release, a merge
proposal with the above solution is available.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/678421
Title:
Error in ~/.profile halts the X startup
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs