Vin Shelton wrote:
> Open KDE Konsole, su to root. Start xemacs.
>
> Following message appears:
>
> -----
> Xlib: connection to ":0.0" refused by server
> Xlib: Invalid XDM-AUTHORIZATION-1 key (failed key comparison)
>
You can not start X applications under root without setting the
XAUTHORITY environment variable appropriately. This should do the
trick:
XAUTHORITY=$HOME/.Xauthority; export XAUTHORITY
(or
setenv XAUTHORITY $HOME/.Xauthority
if you use csh [shudder] as root's shell)
Both of those are no-ops. If XAUTHORITY is unset, $HOME/.Xauthority is
used instead.
The problem is that "su" is changing $HOME, so $HOME/.Xauthority is no
longer valid.
You need to use the actual path to the appropriate directory, e.g.
XAUTHORITY=/home/asmund/.Xauthority ; export XAUTHORITY
--
Glynn Clements <glynn.clements(a)virgin.net>