Corinna Vinschen wrote:
> On Jun 25 12:06, Corinna Vinschen wrote: > > On Jun 24 18:18, Gary Johnson wrote: > > > Ditto. I just finished installing it and successfully running "make > > > test" on > > > > > > Cygwin on Windows XP > > > > Out of curiosity: Which Cygwin version are you running? 1.5.25? > > > > `make test' also builds and runs fine in a test release of the upcoming > > new major Cygwin version 1.7.0. > > btw., beginning with 1.7.0, Cygwin will allow to use long paths on > Windows, longer than the usual MAX_PATH=260 chars. PATH_MAX is now > 4096. > > Right now, vim uses the function cygwin_conv_to_posix_path to convert > Win32 paths to POSIX paths. The problem with this function is that > it only allows to work with MAX_PATH long paths. The reason to keep > it at that is not to break old applications which use static buffers of > MAX_PATH length. > > As a replacement function, we now have the function `cygwin_conv_path', > which allows to deal with paths of arbitrary length. > > Below is a patch which replaces the cygwin_conv_to_posix_path with calls > to cygwin_conv_path, if we build for Cygwin 1.7. This is the simple > approach. Another one would be along the lines of: > > ssize_t size; > char *posix_path; > > size = cygwin_conv_path(CCP_WIN_A_TO_POSIX, p, NULL, 0); > posix_path = (char *) alloca(size); > cygwin_conv_path(CCP_WIN_A_TO_POSIX, p, posix_path, size); > > Please let me know if you would rather like to use that approach > instead of just relying on PATH_MAX. Using an array on the stack looks fine to me. Glad to see the buggy function is being replaced. I'll include this patch one of the coming days. You mention MAX_PATH and PATH_MAX, I think only PATH_MAX is a standard Unix thing. But some (older?) versions of cygwin don't define it, as someone mentioned. -- >From "know your smileys": :'-D Laughing so much that they're crying /// Bram Moolenaar -- [EMAIL PROTECTED] -- 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 /// --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_dev" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
