]> granicus.if.org Git - vim/commitdiff
patch 7.4.1014 v7.4.1014
authorBram Moolenaar <Bram@vim.org>
Thu, 31 Dec 2015 21:26:28 +0000 (22:26 +0100)
committerBram Moolenaar <Bram@vim.org>
Thu, 31 Dec 2015 21:26:28 +0000 (22:26 +0100)
Problem:    fnamemodify('.', ':.') returns an empty string in Cygwin.
Solution:   Use CCP_RELATIVE in the call to cygwin_conv_path. (Jacob Niehus,
            closes #505)

src/os_unix.c
src/version.c

index 89519fad2ace5cb23b55cbf2d73f19d5cfe81c32..d4a0f6dbe8f230e6257d36862129095e237c2cdb 100644 (file)
@@ -2464,7 +2464,10 @@ mch_FullName(fname, buf, len, force)
      * This helps for when "/etc/hosts" is a symlink to "c:/something/hosts".
      */
 # if CYGWIN_VERSION_DLL_MAJOR >= 1007
-    cygwin_conv_path(CCP_WIN_A_TO_POSIX, fname, posix_fname, MAXPATHL);
+    /* Use CCP_RELATIVE to avoid that it sometimes returns a path that ends in
+     * a forward slash. */
+    cygwin_conv_path(CCP_WIN_A_TO_POSIX | CCP_RELATIVE,
+                    fname, posix_fname, MAXPATHL);
 # else
     cygwin_conv_to_posix_path(fname, posix_fname);
 # endif
index f6f0754c64919e4f66febd956d7b678c9edf3294..699a7f6cb387a6c6c1b9f70159a7b1eb70c049eb 100644 (file)
@@ -741,6 +741,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1014,
 /**/
     1013,
 /**/