From f3a183ecc1c642b05dee12a06b3e977d90b49eee Mon Sep 17 00:00:00 2001
From: Abiola Ibrahim <abiola89@gmail.com>
Date: Fri, 11 Mar 2016 15:39:13 +0100
Subject: [PATCH] Use filepath.Clean for fileserver.

---
 middleware/fileserver.go | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/middleware/fileserver.go b/middleware/fileserver.go
index 80cf6f841..9c15900ef 100644
--- a/middleware/fileserver.go
+++ b/middleware/fileserver.go
@@ -4,6 +4,7 @@ import (
 	"net/http"
 	"os"
 	"path"
+	"path/filepath"
 	"strings"
 )
 
@@ -43,7 +44,7 @@ func (fh *fileHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) (int, e
 		upath = "/" + upath
 		r.URL.Path = upath
 	}
-	return fh.serveFile(w, r, path.Clean(upath))
+	return fh.serveFile(w, r, filepath.Clean(upath))
 }
 
 // serveFile writes the specified file to the HTTP response.