4 From: Bram Moolenaar <Bram@moolenaar.net>
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
11 Problem: Opening a file on a network share is very slow.
12 Solution: When fixing file name case append "\*" to directory, server and
13 network share names. (David Anderson, John Beckett)
17 *** ../vim-7.3.026/src/os_win32.c 2010-09-21 17:29:19.000000000 +0200
18 --- src/os_win32.c 2010-10-13 20:31:32.000000000 +0200
24 char szTrueName[_MAX_PATH + 2];
25 + char szTrueNameTemp[_MAX_PATH + 2];
26 char *ptrue, *ptruePrev;
27 char *porig, *porigPrev;
34 flen = (int)STRLEN(name);
35 if (flen == 0 || flen > _MAX_PATH)
41 /* Skip "", "." and "..". */
43 && (ptruePrev[0] != '.'
44 || (ptruePrev[1] != NUL
45 && (ptruePrev[1] != '.' || ptruePrev[2] != NUL)))
46 ! && (hFind = FindFirstFile(szTrueName, &fb))
47 != INVALID_HANDLE_VALUE)
54 + /* To avoid a slow failure append "\*" when searching a directory,
55 + * server or network share. */
56 + STRCPY(szTrueNameTemp, szTrueName);
57 + slen = strlen(szTrueNameTemp);
58 + if (*porig == psepc && slen + 2 < _MAX_PATH)
59 + STRCPY(szTrueNameTemp + slen, "\\*");
61 /* Skip "", "." and "..". */
63 && (ptruePrev[0] != '.'
64 || (ptruePrev[1] != NUL
65 && (ptruePrev[1] != '.' || ptruePrev[2] != NUL)))
66 ! && (hFind = FindFirstFile(szTrueNameTemp, &fb))
67 != INVALID_HANDLE_VALUE)
70 *** ../vim-7.3.026/src/version.c 2010-10-13 18:06:42.000000000 +0200
71 --- src/version.c 2010-10-13 20:37:00.000000000 +0200
75 { /* Add new patch number below this line */
81 A cow comes flying over the battlements, lowing aggressively. The cow
82 lands on GALAHAD'S PAGE, squashing him completely.
83 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
85 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
86 /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
87 \\\ download, build and distribute -- http://www.A-A-P.org ///
88 \\\ help me help AIDS victims -- http://ICCF-Holland.org ///