The problem here is making sure that path_prefix_is() behaves exactly
as would a case insensitive prefixIs(). Anyway, this is still better
than trying to fix the semantics of common_path().
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@29846
a592a061-630c-0410-9148-
cb99ea01b6c8
docstring::size_type const p2_len = p2.length();
docstring::size_type common_len = common_path(p1, p2);
- if (p2[p2_len - 1] == '/')
+ if (p2[p2_len - 1] == '/' && p1_len != p2_len)
++common_len;
if (common_len != p2_len)
docstring::size_type const p2_len = p2.length();
docstring::size_type common_len = common_path(p1, p2);
- if (p2[p2_len - 1] == '/')
+ if (p2[p2_len - 1] == '/' && p1_len != p2_len)
++common_len;
if (common_len != p2_len)
docstring::size_type const p2_len = p2.length();
docstring::size_type common_len = common_path(p1, p2);
- if (p2[p2_len - 1] == '/')
+ if (p2[p2_len - 1] == '/' && p1_len != p2_len)
++common_len;
if (common_len != p2_len)