Changeset 02548b9 in github
- Timestamp:
- Jun 3, 2008 8:23:55 AM (5 years ago)
- Branches:
- master, HEAD, courier-fix, dev-browser-capabilities, pdo, release-0.6, release-0.7, release-0.8
- Children:
- 68217c5
- Parents:
- e47aadc
- Files:
-
- 2 edited
-
CHANGELOG (modified) (1 diff)
-
program/lib/imap.inc (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
CHANGELOG
rd1e8e3f r02548b9 1 1 CHANGELOG RoundCube Webmail 2 2 --------------------------- 3 4 2008/06/03 (alec) 5 ---------- 6 - imap.inc: Fixed iil_MultLine(): use iil_ReadBytes() instead of iil_ReadLine() 7 - imap.inc: Fixed iil_C_FetchStructureString() to handle many 8 literal strings in response (#1484969) 9 - imap.inc: Removed hardcoded data size in iil_ReadLine() 3 10 4 11 2008/05/30 (alec) -
program/lib/imap.inc
rd1e8e3f r02548b9 58 58 - added iil_Escape() with support for " and \ in folder names 59 59 - support \ character in username in iil_C_Login() 60 - fixed iil_MultLine(): use iil_ReadBytes() instead of iil_ReadLine() 61 - fixed iil_C_FetchStructureString() to handle many literal strings in response 62 - removed hardcoded data size in iil_ReadLine() 60 63 61 64 ********************************************************/ … … 172 175 return $line; 173 176 } 177 178 if (!$size) { 179 $size = 1024; 180 } 181 174 182 do { 175 // FIXME: hardcode size? 176 $buffer = fgets($fp, 2048); 183 $buffer = fgets($fp, $size); 177 184 if ($buffer === false) { 178 185 break; … … 191 198 $bytes = $a[2][0]; 192 199 while (strlen($out) < $bytes) { 193 $line = iil_Read Line($fp, 1024);194 $out .= chop($line);200 $line = iil_ReadBytes($fp, $bytes); 201 $out .= $line; 195 202 } 196 203 $line = $a[1][0] . "\"$out\""; … … 2551 2558 $fp = $conn->fp; 2552 2559 $result = false; 2560 2553 2561 if (iil_C_Select($conn, $folder)) { 2554 2562 $key = 'F1247'; … … 2556 2564 if (fputs($fp, "$key FETCH $id (BODYSTRUCTURE)\r\n")) { 2557 2565 do { 2558 $line=chop(iil_ReadLine($fp, 5000)); 2559 if ($line[0] == '*') { 2560 if (ereg("\}$", $line)) { 2561 preg_match('/(.+)\{([0-9]+)\}/', $line, $match); 2562 $result = $match[1]; 2563 do { 2564 $line = chop(iil_ReadLine($fp, 100)); 2565 if (!preg_match("/^$key/", $line)) { 2566 $result .= $line; 2567 } else { 2568 $done = true; 2569 } 2570 } while (!$done); 2571 } else { 2572 $result = $line; 2573 } 2574 list($pre, $post) = explode('BODYSTRUCTURE ', $result); 2575 2576 //truncate last ')' and return 2577 $result = substr($post, 0, strlen($post)-1); 2578 } 2566 $line = iil_ReadLine($fp, 5000); 2567 $line = iil_MultLine($fp, $line); 2568 $result .= $line; 2579 2569 } while (!preg_match("/^$key/", $line)); 2570 2571 $result = trim(substr($result, strpos($result, 'BODYSTRUCTURE')+13, -(strlen($result)-strrpos($result, ')')-1))); 2580 2572 } 2581 2573 }
Note: See TracChangeset
for help on using the changeset viewer.
