avoid double slash
git-svn-id: svn://svn.lighttpd.net/xcache/trunk@174 c26eb9a1-5813-0410-bd6c-c2e55f420ca7
This commit is contained in:
parent
182e31fe5d
commit
9273087b98
|
@ -61,7 +61,9 @@ class XcacheCoverageViewer
|
|||
|
||||
$this->path = isset($_GET['path']) ? $_GET['path'] : '';
|
||||
$this->path = preg_replace('!\.{2,}!', '.', $this->path);
|
||||
$this->path = preg_replace('![\\\\/]{2,}!', '/', $this->path);
|
||||
$qsep = preg_quote(DIRECTORY_SEPARATOR, '!');
|
||||
$this->path = preg_replace("![\\\\$qsep]{2,}!", DIRECTORY_SEPARATOR, $this->path);
|
||||
$this->path = preg_replace("!$qsep$!", '', $this->path);
|
||||
if ($this->path == '/') {
|
||||
$this->path = '';
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue