local/remote how to detect?

Bert Wesarg wesarg at informatik.uni-halle.de
Mon Jul 2 17:12:04 PDT 2007



Carsten Haitzler (The Rasterman) wrote:
> On Mon, 02 Jul 2007 23:15:24 +0200 Bert Wesarg <wesarg at informatik.uni-halle.de>
> babbled:
> 
>>
>> Tiago Vignatti wrote:
>>> Bert Wesarg escreveu:
>>>> Hello All,
>>>>
>>>> [ Maybe a FAQ ]
>>>>
>>>> is it possible to reliable detect if me (the X client) is remote or local
>>>> to the X server?
>>> Maybe the 'xlsclients' tool. The first row of the output will tell which 
>>> machine the client is connected.
>> Thanks, indeed a nice tool. unfortunelatly the client i'm interested (a
>> motif one) is not even listed when all is running local (and yes I used
>> option -a and -l)! all other things like xmms, gkrellm are listed.
> 
> all xlsclients does it walk the window tree and look at window properties for
> title, name/class etc.
> 
> as i suggested before. try create an xshmimage - this will only succeed if you
> are local. tonnes of sample code out there on how to do this (its more than 1
> step).
Yeah I will look into this, but your first response sounds a little bit
like a joke.

I just see that the mplayer checks for a display number < 10 to decide
whether the display is local or remote. how reliable is this? is this
somewhere documented?

regards

> 
>> regards
>> bert
>>
>>>
>>> regards
>>>
>> _______________________________________________
>> xorg mailing list
>> xorg at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/xorg
>>
> 
> 



More information about the xorg mailing list