excerpt
file: smtp.mail.inc
line: 310
description: if either text/plain or text/html is used as text in the mail body, checks done to discern the message content-type are prone to erroneous results
hi,
though this module is awesome, I did spend some time figuring out that having any of either:
- text/plain
- text/html
in the mail body wrecks the delivery ;-)
being more precise:
smtp.mail.inc beginning with line 310 does checks in the following manner:
if (strpos($body_part, 'text/plain')) {
thus - if besides the desired text/plain in the header, text/plain is anywhere in the message body, the result could be false-positive.
matter of factly, I encountered mysterious mail-non-deliveries and started backtracing the missing body element. it turned out to be due to a text/plain within the message body of my mail (intendedly, as I want to mail some CURL protocol parts). this triggered the content-type detection, double filled the AltBody part and left Body empty - resulting in non-delivered mails ;-)
greets,
attisan
Comment | File | Size | Author |
---|---|---|---|
#1 | smtp-content_type_fix-2011592-2.patch | 2.35 KB | attisan |
Comments
Comment #1
attisanif anyone is interested in my fix - see attachment.
hth
attisan
Comment #2
attisan#1: smtp-content_type_fix-2011592-2.patch queued for re-testing.
Comment #3
DamienMcKennaThe patch needs some tidying up to match the Drupal coding standards.
Comment #4
wundo CreditAttribution: wundo at Chuva Inc. for Chuva Inc. commentedComment #5
TR CreditAttribution: TR commentedThis still appears to be an issue with the 8.x-1.x version of SMTP in the SMTPMailSystem.
Moving this issue to 8.x-1.x, as the problem should be solved in the current version first then backported if there is interest and community participation.
Comment #6
japerryOh ick. Marking as active because there is no valid D8 patch for it yet.