To: vim_dev@googlegroups.com Subject: Patch 8.0.0946 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.0.0946 Problem: Using PATH_MAX does not work well on some systems. Solution: use MAXPATHL instead. (James McCoy, closes #1973) Files: src/main.c *** ../vim-8.0.0945/src/main.c 2017-08-06 14:57:44.943764519 +0200 --- src/main.c 2017-08-14 23:38:59.904942377 +0200 *************** *** 2473,2482 **** */ if (vim_strpbrk(p, "\\:") != NULL && !path_with_url(p)) { ! char posix_path[PATH_MAX]; # if CYGWIN_VERSION_DLL_MAJOR >= 1007 ! cygwin_conv_path(CCP_WIN_A_TO_POSIX, p, posix_path, PATH_MAX); # else cygwin_conv_to_posix_path(p, posix_path); # endif --- 2473,2482 ---- */ if (vim_strpbrk(p, "\\:") != NULL && !path_with_url(p)) { ! char posix_path[MAXPATHL]; # if CYGWIN_VERSION_DLL_MAJOR >= 1007 ! cygwin_conv_path(CCP_WIN_A_TO_POSIX, p, posix_path, MAXPATHL); # else cygwin_conv_to_posix_path(p, posix_path); # endif *************** *** 3598,3607 **** char_u *val = argv0; # ifdef PROC_EXE_LINK ! char buf[PATH_MAX + 1]; ssize_t len; ! len = readlink(PROC_EXE_LINK, buf, PATH_MAX); if (len > 0) { buf[len] = NUL; --- 3598,3607 ---- char_u *val = argv0; # ifdef PROC_EXE_LINK ! char buf[MAXPATHL + 1]; ssize_t len; ! len = readlink(PROC_EXE_LINK, buf, MAXPATHL); if (len > 0) { buf[len] = NUL; *** ../vim-8.0.0945/src/version.c 2017-08-14 23:25:00.494052007 +0200 --- src/version.c 2017-08-14 23:39:44.520670599 +0200 *************** *** 771,772 **** --- 771,774 ---- { /* Add new patch number below this line */ + /**/ + 946, /**/ -- Mushrooms always grow in damp places and so they look like umbrellas. /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///