diff options
| author | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-12-03 11:40:59 +0000 |
|---|---|---|
| committer | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-12-03 11:40:59 +0000 |
| commit | 9b861076be1c5afa95ff5b7566757cbf7f03eee2 (patch) | |
| tree | cb5ca54e9376c2ca77cb56181b57c67da94207da /roundcubemail/program/lib/Net | |
| parent | 1baababe36188c43f3fcb4e6f2f63ac85ed46acd (diff) | |
- Net_SMTP 1.3.4
git-svn-id: https://svn.roundcube.net/trunk@3154 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/lib/Net')
| -rw-r--r-- | roundcubemail/program/lib/Net/SMTP.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/roundcubemail/program/lib/Net/SMTP.php b/roundcubemail/program/lib/Net/SMTP.php index 9b835d723..6df13a029 100644 --- a/roundcubemail/program/lib/Net/SMTP.php +++ b/roundcubemail/program/lib/Net/SMTP.php @@ -226,9 +226,10 @@ class Net_SMTP { $this->_debug("Send: $data"); - if (PEAR::isError($error = $this->_socket->write($data))) { - return PEAR::raiseError('Failed to write to socket: ' . - $error->getMessage()); + $error = $this->_socket->write($data); + if ($error === false || PEAR::isError($error)) { + $msg = ($error) ? $error->getMessage() : "unknown error"; + return PEAR::raiseError("Failed to write to socket: $msg"); } return true; |
