Explorar o código

Fixed bug in readShortMailboxName() if "needle" (delimiter) is empty.

pallo %!s(int64=24) %!d(string=hai) anos
pai
achega
d05b70622e
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      functions/strings.php

+ 1 - 0
functions/strings.php

@@ -15,6 +15,7 @@
    //    of the $haystack is reached.  $needle is a single character
    //*************************************************************************
    function readShortMailboxName($haystack, $needle) {
+      if ($needle == "") return $haystack;
       if ($needle == ".") $needle = "\.";
       ereg("([^$needle]+)$needle?$", $haystack, $regs);
       return $regs[1];