patch 8.2.0985: simplify() does not remove slashes from "///path"
Problem: Simplify() does not remove slashes from "///path".
Solution: Reduce > 2 slashes to one. (closes #6263)
diff --git a/src/findfile.c b/src/findfile.c
index 2139d8b..b153ed0 100644
--- a/src/findfile.c
+++ b/src/findfile.c
@@ -2641,6 +2641,14 @@
while (vim_ispathsep(*p));
}
start = p; // remember start after "c:/" or "/" or "///"
+#ifdef UNIX
+ // Posix says that "//path" is unchanged but "///path" is "/path".
+ if (start > filename + 2)
+ {
+ STRMOVE(filename + 1, p);
+ start = p = filename + 1;
+ }
+#endif
do
{