diff options
| author | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-03-31 14:47:22 +0000 |
|---|---|---|
| committer | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-03-31 14:47:22 +0000 |
| commit | e90633c571ebb827dd76c1b09980850101be72fb (patch) | |
| tree | a2751beb74ed88aff00ae17084cb2c4d51d511ea /roundcubemail/program | |
| parent | cc219ec36972208774553df7207ee57e3fff1ca8 (diff) | |
- Fix using mail() on Windows (#1485779)
git-svn-id: https://svn.roundcube.net/trunk@2370 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program')
| -rw-r--r-- | roundcubemail/program/steps/mail/func.inc | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/roundcubemail/program/steps/mail/func.inc b/roundcubemail/program/steps/mail/func.inc index a76532cb9..f9d560a97 100644 --- a/roundcubemail/program/steps/mail/func.inc +++ b/roundcubemail/program/steps/mail/func.inc @@ -1308,7 +1308,14 @@ function rcmail_deliver_message(&$message, $from, $mailto) // reset stored headers and overwrite $message->_headers = array(); $header_str = $message->txtHeaders($headers_php); - + + // #1485779 + if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') { + if (preg_match_all('/<([^@]+@[^>]+)>/', $headers_enc['To'], $m)) { + $headers_enc['To'] = implode(', ', $m[1]); + } + } + if (ini_get('safe_mode')) $sent = mail($headers_enc['To'], $headers_enc['Subject'], $msg_body, $header_str); else |
