On Tue, Jan 18, 2000 at 02:01:45PM -0000, John Horne wrote:
> Hi,
> 
> Odd question this. Using my PC (RH6.1 with KDE) I telnetted to another linux
> box. From there I went to vi a file and briefly saw an error message before
> vi started. Quitting vi showed the error still on the screen:
> 
>   Xlib: connection to "jhorne.csd.plymouth.ac.uk:0.0" refused by server
>   Xlib: Client is not authorized to connect to Server
> 
 It seems that some Versions of vim with gui support compiled in seem 
 to check if they can open an X connection even if they are invoked
 as a non-gui version. Maybe it's a bug?

> 
> Another thing is - why does 'vimx' give an ordinary X session, even on the
> local system, whereas gvim does as expected and opens an X window? vimx is
> just a link to gvim.
>
 when vim is invoked, it is given a list of command line arguments. The
 first one, argv[0] is a string containing the name under which vim is 
 invoked, it then does a lookup against

 vi
 gvim
 gview
 view

 and some others, then decides what to do based on what name it was invoked
 under. So when it's linked it has a different name and does different stuff
 based on which one it was invoked as. For an extreme version of this, look
 at busybox:
ftp://ftp.perens.com/pub/BusyBox/

  It's one program that gets linked to do the job of about thirty.

have fun vi'ing

greg

-- 
this is not here

Reply via email to