Blob Blame History Raw
To: vim-dev@vim.org
Subject: patch 7.0.228
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
------------

Patch 7.0.228
Problem:    Cygwin: problem with symlink to DOS style path.
Solution:   Invoke cygwin_conv_to_posix_path(). (Luca Masini)
Files:	    src/os_unix.c


*** ../vim-7.0.227/src/os_unix.c	Tue Mar  6 20:27:03 2007
--- src/os_unix.c	Mon Apr 23 22:27:16 2007
***************
*** 55,60 ****
--- 55,66 ----
  # endif
  #endif
  
+ #ifdef __CYGWIN__
+ # ifndef WIN32
+ #  include <sys/cygwin.h>	/* for cygwin_conv_to_posix_path() */
+ # endif
+ #endif
+ 
  #if defined(HAVE_SELECT)
  extern int   select __ARGS((int, fd_set *, fd_set *, fd_set *, struct timeval *));
  #endif
***************
*** 2228,2233 ****
--- 2258,2270 ----
  
  #ifdef VMS
      fname = vms_fixfilename(fname);
+ #endif
+ 
+ #ifdef __CYGWIN__
+     /*
+      * This helps for when "/etc/hosts" is a symlink to "c:/something/hosts".
+      */
+     cygwin_conv_to_posix_path(fname, fname);
  #endif
  
      /* expand it if forced or not an absolute path */
*** ../vim-7.0.227/src/version.c	Thu Apr 26 16:11:47 2007
--- src/version.c	Thu Apr 26 16:27:29 2007
***************
*** 668,669 ****
--- 668,671 ----
  {   /* Add new patch number below this line */
+ /**/
+     228,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
19. All of your friends have an @ in their names.

 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\        download, build and distribute -- http://www.A-A-P.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///