summaryrefslogtreecommitdiffstats
path: root/src/main
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2014-10-13 18:06:28 -0400
committerJames Moger <james.moger@gitblit.com>2014-10-13 18:06:28 -0400
commitb236d715383920b7c92c035dcf769114011fa426 (patch)
tree4a17a8c1d3f4e5388aab319d093c8c6444c83887 /src/main
parent6e0cef9554c61d514ca368c85b512f85fd5be0f0 (diff)
downloadgitblit-b236d715383920b7c92c035dcf769114011fa426.tar.gz
gitblit-b236d715383920b7c92c035dcf769114011fa426.zip
Fix backslash regression in relative path determiniation
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/com/gitblit/utils/FileUtils.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/com/gitblit/utils/FileUtils.java b/src/main/java/com/gitblit/utils/FileUtils.java
index 27caa7ea..e7f01045 100644
--- a/src/main/java/com/gitblit/utils/FileUtils.java
+++ b/src/main/java/com/gitblit/utils/FileUtils.java
@@ -296,7 +296,7 @@ public class FileUtils {
Path exactBase = Paths.get(getExactFile(basePath).toURI());
Path exactPath = Paths.get(getExactFile(path).toURI());
if (exactPath.startsWith(exactBase)) {
- return exactBase.relativize(exactPath).toString();
+ return exactBase.relativize(exactPath).toString().replace('\\', '/');
}
// no relative relationship
return null;