From c50fa82bec631b018fd6288d97b7813dc86daf20 Mon Sep 17 00:00:00 2001
From: Thomas Bruederli <thomas@roundcube.net>
Date: Tue, 06 Nov 2012 07:21:11 -0500
Subject: [PATCH] Merge branch 'master' of github.com:roundcube/roundcubemail

---
 program/include/rcube_imap_generic.php |   18 +++++-------------
 1 files changed, 5 insertions(+), 13 deletions(-)

diff --git a/program/include/rcube_imap_generic.php b/program/include/rcube_imap_generic.php
index 52bf0e3..651de9d 100644
--- a/program/include/rcube_imap_generic.php
+++ b/program/include/rcube_imap_generic.php
@@ -3530,6 +3530,10 @@
      */
     static function uncompressMessageSet($messages)
     {
+        if (empty($messages)) {
+            return array();
+        }
+
         $result   = array();
         $messages = explode(',', $messages);
 
@@ -3538,7 +3542,7 @@
             $max   = max($items[0], $items[1]);
 
             for ($x=$items[0]; $x<=$max; $x++) {
-                $result[] = $x;
+                $result[] = (int)$x;
             }
             unset($messages[$idx]);
         }
@@ -3651,18 +3655,6 @@
 
         // literal-string
         return sprintf("{%d}\r\n%s", strlen($string), $string);
-    }
-
-    /**
-     * Unescapes quoted-string
-     *
-     * @param string  $string       IMAP string
-     *
-     * @return string String
-     */
-    static function unEscape($string)
-    {
-        return stripslashes($string);
     }
 
     /**

--
Gitblit v1.9.1