Thomas Bruederli
2014-04-08 1d1fdcbf8cd7cce93454eb0b64eaf76975ebdd17
Fix splitting message identifiers into UID and folder values
3 files modified
8 ■■■■ changed files
program/lib/Roundcube/rcube_imap.php 4 ●●●● patch | view | raw | blame | history
program/lib/Roundcube/rcube_message.php 2 ●●● patch | view | raw | blame | history
program/steps/mail/func.inc 2 ●●● patch | view | raw | blame | history
program/lib/Roundcube/rcube_imap.php
@@ -1709,7 +1709,7 @@
        // decode combined UID-folder identifier
        if (preg_match('/^\d+-[^,]+$/', $uid)) {
            list($uid, $folder) = explode('-', $uid);
            list($uid, $folder) = explode('-', $uid, 2);
        }
        // get cached headers
@@ -1745,7 +1745,7 @@
        // decode combined UID-folder identifier
        if (preg_match('/^\d+-[^,]+$/', $uid)) {
            list($uid, $folder) = explode('-', $uid);
            list($uid, $folder) = explode('-', $uid, 2);
        }
        // Check internal cache
program/lib/Roundcube/rcube_message.php
@@ -76,7 +76,7 @@
    {
        // decode combined UID-folder identifier
        if (preg_match('/^\d+-[^,]+$/', $uid)) {
            list($uid, $folder) = explode('-', $uid);
            list($uid, $folder) = explode('-', $uid, 2);
        }
        $this->uid  = $uid;
program/steps/mail/func.inc
@@ -70,7 +70,7 @@
// remove mbox part from _uid
if (($_uid  = get_input_value('_uid', RCUBE_INPUT_GPC)) && preg_match('/^\d+-[^,]+$/', $_uid)) {
  list($_uid, $mbox) = explode('-', $_uid);
  list($_uid, $mbox) = explode('-', $_uid, 2);
  if (isset($_GET['_uid']))  $_GET['_uid']  = $_uid;
  if (isset($_POST['_uid'])) $_POST['_uid'] = $_uid;
  $_REQUEST['_uid'] = $_uid;