Skip to content
Snippets Groups Projects
Commit 8980356f authored by Peter Rotich's avatar Peter Rotich
Browse files

Merge pull request #624 from greezybacon/issue/imap-base64-fails


Fallback to base64_decode if imap_base64 fails
Reviewed-By: default avatarPeter Rotich <peter@osticket.com>
parents c3e9e27a 6f375159
No related branches found
No related tags found
No related merge requests found
......@@ -181,7 +181,9 @@ class MailFetcher {
$text=imap_binary($text);
break;
case 3:
$text=imap_base64($text);
// imap_base64 implies strict mode. If it refuses to decode the
// data, then fallback to base64_decode in non-strict mode
$text = (($conv=imap_base64($text))) ? $conv : base64_decode($text);
break;
case 4:
$text=imap_qprint($text);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment