b306747
To: vim-dev@vim.org
b306747
Subject: Patch 7.0.052
b306747
Fcc: outbox
b306747
From: Bram Moolenaar <Bram@moolenaar.net>
b306747
Mime-Version: 1.0
b306747
Content-Type: text/plain; charset=ISO-8859-1
b306747
Content-Transfer-Encoding: 8bit
b306747
------------
b306747
b306747
Patch 7.0.052
b306747
Problem:    The user may not be aware that the Vim server allows others more
b306747
	    functionality than desired.
b306747
Solution:   When running Vim as root don't become a Vim server without an
b306747
	    explicit --servername argument.
b306747
Files:	    src/main.c
b306747
b306747
b306747
*** ../vim-7.0.051/src/main.c	Mon Jun 19 10:56:20 2006
b306747
--- src/main.c	Tue Aug  8 11:02:44 2006
b306747
***************
b306747
*** 3212,3221 ****
b306747
       * Register for remote command execution with :serversend and --remote
b306747
       * unless there was a -X or a --servername '' on the command line.
b306747
       * Only register nongui-vim's with an explicit --servername argument.
b306747
       */
b306747
      if (X_DISPLAY != NULL && parmp->servername != NULL && (
b306747
  #  ifdef FEAT_GUI
b306747
! 		gui.in_use ||
b306747
  #  endif
b306747
  		parmp->serverName_arg != NULL))
b306747
      {
b306747
--- 3212,3226 ----
b306747
       * Register for remote command execution with :serversend and --remote
b306747
       * unless there was a -X or a --servername '' on the command line.
b306747
       * Only register nongui-vim's with an explicit --servername argument.
b306747
+      * When running as root --servername is also required.
b306747
       */
b306747
      if (X_DISPLAY != NULL && parmp->servername != NULL && (
b306747
  #  ifdef FEAT_GUI
b306747
! 		(gui.in_use
b306747
! #   ifdef UNIX
b306747
! 		 && getuid() != 0
b306747
! #   endif
b306747
! 		) ||
b306747
  #  endif
b306747
  		parmp->serverName_arg != NULL))
b306747
      {
b306747
*** ../vim-7.0.051/src/version.c	Fri Aug 11 22:56:44 2006
b306747
--- src/version.c	Tue Aug 15 21:41:24 2006
b306747
***************
b306747
*** 668,669 ****
b306747
--- 668,671 ----
b306747
  {   /* Add new patch number below this line */
b306747
+ /**/
b306747
+     52,
b306747
  /**/
b306747
b306747
-- 
b306747
hundred-and-one symptoms of being an internet addict:
b306747
148. You find it easier to dial-up the National Weather Service
b306747
     Weather/your_town/now.html than to simply look out the window.
b306747
b306747
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
b306747
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
b306747
\\\        download, build and distribute -- http://www.A-A-P.org        ///
b306747
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///