Changeset 9273087 in git


Ignore:
Timestamp:
2006-09-17T02:14:51Z (13 years ago)
Author:
Xuefer <xuefer@…>
Branches:
1.2, 1.3, 3.0, 3.1, 3.2, master, trunk
Children:
4dfb67b
Parents:
182e31f
Message:

avoid double slash

git-svn-id: svn://svn.lighttpd.net/xcache/trunk@174 c26eb9a1-5813-0410-bd6c-c2e55f420ca7

File:
1 edited

Legend:

Unmodified
Added
Removed
  • coverager/coverager.php

    re96f9d5 r9273087  
    6262        $this->path = isset($_GET['path']) ? $_GET['path'] : '';
    6363        $this->path = preg_replace('!\.{2,}!', '.', $this->path);
    64         $this->path = preg_replace('![\\\\/]{2,}!', '/', $this->path);
     64        $qsep = preg_quote(DIRECTORY_SEPARATOR, '!');
     65        $this->path = preg_replace("![\\\\$qsep]{2,}!", DIRECTORY_SEPARATOR, $this->path);
     66        $this->path = preg_replace("!$qsep$!", '', $this->path);
    6567        if ($this->path == '/') {
    6668            $this->path = '';
Note: See TracChangeset for help on using the changeset viewer.