Christian Brabandt wrote:
> Bram,
> I noticed since some versions, one cannot do
> :cd \\foobar\share
> anymore. It aborts with something like
> E344: Can't find directory \\foobar\share in cdpath
>
> I tracked it down to patch 7.3.1182
>
> Here is a patch, please include.
> diff -r 58bcf8fa172f src/os_win32.c
> --- a/src/os_win32.c Sun Nov 17 20:32:54 2013 +0100
> +++ b/src/os_win32.c Tue Nov 19 21:29:57 2013 +0100
> @@ -2851,6 +2851,12 @@
> struct stat st;
> int n;
>
> + if (name[0] != NUL &&
> + name[0] == '\\' &&
> + name[1] != NUL &&
> + name[1] == '\\')
> + /* UNC path */
> + return win32_getattrs(name);
> n = mch_stat(name, &st);
> return n == 0 ? (int)st.st_mode : -1;
> }
Why the checks for NUL? Looks like you can just leave them out.
--
Are leaders born or made? And if they're made, can we return them under
warranty?
(Scott Adams - The Dilbert principle)
/// Bram Moolenaar -- [email protected] -- 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 ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.