Browse Source

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

pallo 24 năm trước cách đây
mục cha
commit
d05b70622e
1 tập tin đã thay đổi với 1 bổ sung0 xóa
  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];