Blob Blame History Raw
diff -Naurp captcha-2.3.orig/captcha.php captcha-2.3.new/captcha.php
--- captcha-2.3.orig/captcha.php	2019-07-22 11:16:39.304109315 +0200
+++ captcha-2.3.new/captcha.php	2019-07-22 11:58:15.708390321 +0200
@@ -1235,7 +1235,6 @@ END_____JSRPC__JSRPC__JSRPC__JSRPC__JSRP
 
      $path = array();
      $abspath = substr("$url ", 0, 1) == '/'? '/': '';
-     $ncomp = 0;
 
      foreach (explode('/', $url) as $comp)
        switch ($comp) {
@@ -1245,14 +1244,13 @@ END_____JSRPC__JSRPC__JSRPC__JSRPC__JSRP
          break;
 
        case '..':
-         if ($ncomp--) {
+         if ($path) {
            array_pop($path);
            break;
          }
 
        default:
          $path[] = $comp;
-         $ncomp++;
          break;
        }