Commit 33da0aa
committed
improve diagnostics on connect and TLS failures
- connect(): include the OS error code/message from stream_socket_client()
so failures report 'Connection refused', 'Connection timed out', etc.
instead of the uninformative 'Could not open SMTP Port'.
- starttls(): suppress the misleading PHP warning from
stream_socket_enable_crypto() (often 'SSL: Success') and append the real
OpenSSL reason from error_get_last() to the CryptoException.1 parent ee4c1ef commit 33da0aa
1 file changed
Lines changed: 10 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
224 | 224 | | |
225 | 225 | | |
226 | 226 | | |
227 | | - | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
228 | 231 | | |
229 | 232 | | |
230 | 233 | | |
| |||
259 | 262 | | |
260 | 263 | | |
261 | 264 | | |
262 | | - | |
263 | | - | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
264 | 271 | | |
265 | 272 | | |
266 | 273 | | |
| |||
0 commit comments