Re: how to find out what port the X server is listening on?
Re: how to find out what port the X server is listening on?
- Subject: Re: how to find out what port the X server is listening on?
- From: Bill Janssen <email@hidden>
- Date: Thu, 30 Jan 2014 11:59:42 -0800
- Comments: In-reply-to Jeremy Huddleston Sequoia <email@hidden> message dated "Thu, 30 Jan 2014 11:27:07 -0800."
Jeremy Huddleston Sequoia <email@hidden> wrote:
> Or you can stash it somewhere by using a script in ~/.xinitrc.d since xinitrc uses the legacy socket.
Ah! That sounds like the plan, then. I'll write a little Python Xlib
script to grab the peer socket port from the client-side Display object.
Thanks.
Bill
>
> On Jan 30, 2014, at 11:19, Brandon Allbery <email@hidden> wrote:
>
> > On Thu, Jan 30, 2014 at 2:07 PM, Bill Janssen <email@hidden> wrote:
> > Of course, the DISPLAY variable could track the port # properly, too,
> > just as a convenience to the user. Then I could pull it off of that.
> >
> > I think that's difficult, because the DISPLAY variable is determined by launchd but the actual port used is probably determined by Xquartz?
> >
> > Aaaaand... I'm playing around with lsof here and think something may be broken: -c works by itself, -i works by itself, -a does not appear to AND them but suppresses output completely (as if the intersection of Xquartz and internet socket is empty instead of showing the TCP listen socket and any connected clients), omitting -a produces the expected OR behavior (which is useless here). :(
> >
> > --
> > brandon s allbery kf8nh sine nomine associates
> > email@hidden email@hidden
> > unix, openafs, kerberos, infrastructure, xmonad http://sinenomine.net
> > _______________________________________________
> > Do not post admin requests to the list. They will be ignored.
> > X11-users mailing list (email@hidden)
> >
> > This email sent to email@hidden
>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
X11-users mailing list (email@hidden)
This email sent to email@hidden