Skip to content

Commit

Permalink
Fix SMTP message address-list issue #348.
Browse files Browse the repository at this point in the history
  • Loading branch information
mobizt committed Jul 15, 2024
1 parent 9197930 commit 7efbf5b
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 11 deletions.
4 changes: 2 additions & 2 deletions library.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ESP Mail Client",
"version": "3.4.19",
"version": "3.4.20",
"keywords": "communication, email, imap, smtp, esp32, esp8266, samd, arduino",
"description": "Arduino E-Mail Client Library to send, read and get incoming email notification for ESP32, ESP8266 and SAMD21 devices. The library also supported other Arduino Devices using Clients interfaces e.g. WiFiClient, EthernetClient, and GSMClient.",
"repository": {
Expand All @@ -12,5 +12,5 @@
"email": "suwatchai@outlook.com"
}],
"frameworks": "arduino",
"platforms": "espressif32, espressif8266, atmelsam, atmelavr, atmelmegaavr, ststm32, teensy, rp2040"
"platforms": "espressif32, espressif8266, atmelsam, atmelavr, atmelmegaavr, ststm32, teensy, rp2040, renesas-ra"
}
4 changes: 2 additions & 2 deletions library.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name=ESP Mail Client

version=3.4.19
version=3.4.20

author=Mobizt

Expand All @@ -14,4 +14,4 @@ category=Communication

url=https://github.com/mobizt/ESP-Mail-Client

architectures=esp8266,esp32,sam,samd,stm32,STM32F1,STM32F4,teensy,avr,megaavr,mbed_nano,mbed_rp2040,rp2040
architectures=esp8266,esp32,sam,samd,stm32,STM32F1,STM32F4,teensy,avr,megaavr,mbed_nano,mbed_rp2040,rp2040, renesas_uno
14 changes: 10 additions & 4 deletions src/ESP_Mail_Client.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@

#pragma GCC diagnostic ignored "-Wunused-but-set-variable"


/**
* Mail Client Arduino Library for Arduino devices.
*
* Created September 13, 2023
* Created July 15, 2024
*
* This library allows Espressif's ESP32, ESP8266, SAMD and RP2040 Pico devices to send and read Email through the SMTP and IMAP servers.
*
Expand Down Expand Up @@ -796,13 +795,20 @@ void ESP_Mail_Client::appendHeaderField(MB_String &buf, const char *name, PGM_P

void ESP_Mail_Client::appendAddressHeaderField(MB_String &buf, esp_mail_address_info_t &source, esp_mail_rfc822_header_field_types type, bool header, bool comma, bool newLine, bool encode)
{

yield_impl();

// Construct header field.
if (header)
appendHeaderName(buf, rfc822_headers[type].text);

if (type != esp_mail_rfc822_header_field_cc && type != esp_mail_rfc822_header_field_bcc &&
source.name.length() > 0)
if (type != esp_mail_rfc822_header_field_cc && type != esp_mail_rfc822_header_field_bcc && source.name.length() > 0)
{
if (comma)
buf += esp_mail_str_8; /* "," */

comma = false;

appendString(buf, encode ? encodeBUTF8(source.name.c_str()).c_str() : source.name.c_str(), false, false, esp_mail_string_mark_type_double_quote);
// Add white space after name for SMTP to fix iCloud Mail Service IMAP search compatibility issue #278
// This is not restricted by rfc2822.
Expand Down
2 changes: 1 addition & 1 deletion src/ESP_Mail_Client.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/**
* Mail Client Arduino Library for Arduino devices.
*
* Created September 13, 2023
* Created July 15, 2024
*
* This library allows Espressif's ESP32, ESP8266, SAMD and RP2040 Pico devices to send and read Email through the SMTP and IMAP servers.
*
Expand Down
4 changes: 2 additions & 2 deletions src/ESP_Mail_Client_Version.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

#ifndef ESP_MAIL_VERSION

#define ESP_MAIL_VERSION "3.4.19"
#define ESP_MAIL_VERSION_NUM 30419
#define ESP_MAIL_VERSION "3.4.20"
#define ESP_MAIL_VERSION_NUM 30420

/* The inconsistent file version checking to prevent mixed versions compilation. */
//#define VALID_VERSION_CHECK(ver) (ver == ESP_MAIL_VERSION_NUM)
Expand Down

0 comments on commit 7efbf5b

Please sign in to comment.