This repository has been archived by the owner on Nov 17, 2021. It is now read-only.
Error suppression causes important debug information to be lost #1201
Comments
Should be fixed by #1202. |
fabpot
added a commit
that referenced
this issue
Jun 27, 2019
…or before connect() (fabpot) This PR was merged into the 6.2-dev branch. Discussion ---------- Fix error message when connecting to a stream raises an error before connect() | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | Doc update? | no | BC breaks? | no | Deprecations? | no | Fixed tickets | #1201 | License | MIT <!-- Replace this comment by the description of your issue. --> Commits ------- 28a0e25 fixed error message when connecting to a stream raises an error before connect()
fabpot
added a commit
to symfony/symfony
that referenced
this issue
Jun 27, 2019
…ses an error before connect() (fabpot) This PR was merged into the 4.3 branch. Discussion ---------- [Mailer] Fix error message when connecting to a stream raises an error before connect() | Q | A | ------------- | --- | Branch? | 4.3 | Bug fix? | yes | New feature? | no <!-- please update src/**/CHANGELOG.md files --> | BC breaks? | no <!-- see https://symfony.com/bc --> | Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files --> | Tests pass? | yes <!-- please add some, will be required by reviewers --> | Fixed tickets | see swiftmailer/swiftmailer#1201 | License | MIT | Doc PR | n/a According to the PHP docs, "If the value returned in errno is 0 and the function returned FALSE, it is an indication that the error occurred before the connect() call.". Using the `@` operator means that we get a generic error message without any clues about why connection cannot be done. Using an error handler allows to get the real issue. Commits ------- eb15bff [Mailer] fixed error message when connecting to a stream raises an error before connect()
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Observed behaviour
Error suppression causes warnings from
stream_socket_client
to be hidden anderrno
is 0.Expected behaviour
Warnings from
stream_socket_client
should not be hidden by default.Example
When trying to connect to a mail server with
ssl
at port465
, with error suppression:Without error suppression:
Error is suppressed at line 267 in
StreamBuffer.php
:The text was updated successfully, but these errors were encountered: