This is the mail archive of the
cygwin-xfree@cygwin.com
mailing list for the Cygwin XFree86 project.
RE: Strange xhost behavior- Please help!!
- From: "Dawson, David W" <david dot w dot dawson at lmco dot com>
- To: "'cygwin-xfree at cygwin dot com'" <cygwin-xfree at cygwin dot com>
- Date: Mon, 04 Nov 2002 14:00:20 -0500
- Subject: RE: Strange xhost behavior- Please help!!
- Reply-to: cygwin-xfree at cygwin dot com
The problem is a "feeture" of all X-servers:
When the X-server detects that the last client connection terminates, the
server does a full reset.
xhost is NOT a persistent connection.
As soon as the xhost program completes it's job (telling the X-Server host
to change the permissions), the xhost program closes it's connection with
the X-server. Since (in your case) it is the ONLY connection at that time,
the X-server resets and promptly eradicates the xhost setting.
You need to open a persistent connection first: an xterm, a window manager,
xclock, something....
-D.
---------------------
David Dawson
david.w.dawson@lmco.com
703-367-3885
-----Original Message-----
From: Kercso Jozsef [mailto:jozsefke@freemail.hu]
Sent: Monday, November 04, 2002 1:25 PM
To: cygwin-xfree@cygwin.com
Subject: Strange xhost behavior- Please help!!
Hi!
I have the following problem:
- I have started a bash consol window as usual with "cygwin.bat"
$> XWin.exe &
$> export DISPLAY=127.0.0.1:0.0
$> xhost +
Then from another host:
[einstein]$ export DISPLAY=127.0.0.1:0.0
[einstein]$ xterm &
Xlib: connection to "127.0.01:0.0" refused by server
Xlib: No protocol specified
Then at the original host:
$> xterm &
# The window was accepted and displayed
Second try from einstein:
[einstein]$ xterm &
Xlib: connection to "127.0.01:0.0" refused by server
Xlib: No protocol specified
Then at the original host:
$> xhost +
Third try from einstein:
[einstein]$ xterm &
# The window was accepted and displayed
So, the X server first needs an xterm from the original host, only
after that will accept connection from another hosts. I have found, that
the second "xhost +" works from the in the X server previously
displayed xterm too.
Why is this so? Why the first "xhost +" does not work?
Can anybody help me? (I have the latest X server:4.2.0-1).
Thanks,
Jozsef Kercso