Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Mailer] Handle failure when sending DATA #39597

Merged
merged 1 commit into from Dec 24, 2020

Conversation

jderusse
Copy link
Member

@jderusse jderusse commented Dec 21, 2020

Q A
Branch? 4.4
Bug fix? yes
New feature? no
Deprecations? no
Tickets -
License MIT
Doc PR -

When an exception is thrown while sending an email via SMTP (ie. A attachment is not readable) the SMTP connection is left opened with a partial message sent.

This PR closes the connection (we can't abort after sending the DATA command) in such situation.

/cc @fabpot

@carsonbot carsonbot changed the title Handle failure when sending DATA [Mailer] Handle failure when sending DATA Dec 21, 2020
fabpot
fabpot approved these changes Dec 22, 2020
@nicolas-grekas
Copy link
Member

@nicolas-grekas nicolas-grekas commented Dec 23, 2020

(there is a related test failure apparently)

@jderusse
Copy link
Member Author

@jderusse jderusse commented Dec 23, 2020

good catch @nicolas-grekas the exception message changed in Mime component in the last version.

Test fixed.

@jderusse jderusse merged commit 457c8b1 into symfony:4.4 Dec 24, 2020
4 of 5 checks passed
@jderusse jderusse deleted the fix-invalid-message branch Dec 24, 2020
This was referenced Jan 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants