diff --git a/README.md b/README.md index 4da8501..a87308d 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Mail Client Arduino Library for ESP32 v 1.2.1 +# Mail Client Arduino Library for ESP32 v 1.2.2 This library allows ESP32 to send Email with/without attachment and receive Email with/without attachment download via SMTP and IMAP servers. diff --git a/library.properties b/library.properties index d57fb94..b2cb9f4 100644 --- a/library.properties +++ b/library.properties @@ -1,6 +1,6 @@ name=ESP32 Mail Client -version=1.2.1 +version=1.2.2 author=Mobizt diff --git a/src/ESP32_MailClient.cpp b/src/ESP32_MailClient.cpp index 5b9f315..6ad1f85 100644 --- a/src/ESP32_MailClient.cpp +++ b/src/ESP32_MailClient.cpp @@ -1,7 +1,7 @@ /* - *Mail Client Arduino Library for ESP32, version 1.2.1 + *Mail Client Arduino Library for ESP32, version 1.2.2 * - * August 7, 2019 + * August 9, 2019 * * This library allows ESP32 to send Email with/without attachment and receive Email with/without attachment download through SMTP and IMAP servers. * @@ -1009,6 +1009,7 @@ bool ESP32_MailClient::sendMail(HTTPClientESP32Ex &http, SMTPData &smtpData) http.setDebugCallback(NULL); + WiFiClient *client; if (smtpData._sendCallback) diff --git a/src/ESP32_MailClient.h b/src/ESP32_MailClient.h index 266368f..0d3c345 100644 --- a/src/ESP32_MailClient.h +++ b/src/ESP32_MailClient.h @@ -1,7 +1,7 @@ /* - *Mail Client Arduino Library for ESP32, version 1.2.1 + *Mail Client Arduino Library for ESP32, version 1.2.2 * - * August 7, 2019 + * August 9, 2019 * * This library allows ESP32 to send Email with/without attachment and receive Email with/without attachment download through SMTP and IMAP servers. * diff --git a/src/HTTPClientESP32Ex.cpp b/src/HTTPClientESP32Ex.cpp index c2634f1..72356f6 100644 --- a/src/HTTPClientESP32Ex.cpp +++ b/src/HTTPClientESP32Ex.cpp @@ -2,7 +2,7 @@ * Customized version of ESP32 HTTPClient Library. * Allow custom header and payload with STARTTLS support * - * v 1.1.1 + * v 1.1.2 * * The MIT License (MIT) * Copyright (c) 2019 K. Suwatchai (Mobizt) diff --git a/src/HTTPClientESP32Ex.h b/src/HTTPClientESP32Ex.h index 61b50c2..451d25f 100644 --- a/src/HTTPClientESP32Ex.h +++ b/src/HTTPClientESP32Ex.h @@ -2,7 +2,7 @@ * Customized version of ESP32 HTTPClient Library. * Allow custom header and payload with STARTTLS support * - * v 1.1.1 + * v 1.1.2 * * The MIT License (MIT) * Copyright (c) 2019 K. Suwatchai (Mobizt) diff --git a/src/ssl_client32.cpp b/src/ssl_client32.cpp index 846ff20..87d94a0 100644 --- a/src/ssl_client32.cpp +++ b/src/ssl_client32.cpp @@ -1,5 +1,5 @@ /* - *Customized ssl_client.cpp to support STARTTLS protocol, version 1.0.1 + *Customized ssl_client.cpp to support STARTTLS protocol, version 1.0.2 * * The MIT License (MIT) * Copyright (c) 2019 K. Suwatchai (Mobizt) @@ -498,7 +498,7 @@ int data_to_read(sslclient_context32 *ssl_client) int send_ssl_data(sslclient_context32 *ssl_client, const uint8_t *data, uint16_t len) { - + log_v("Writing HTTP request..."); //for low level debug int ret = -1; @@ -517,7 +517,7 @@ int send_ssl_data(sslclient_context32 *ssl_client, const uint8_t *data, uint16_t int get_ssl_receive(sslclient_context32 *ssl_client, uint8_t *data, int length) { - + //log_d( "Reading HTTP response..."); //for low level debug int ret = -1; @@ -785,7 +785,8 @@ int starttlsHandshake(sslclient_context32 *ssl_client, int port) memset(hMsg, 0, msgLen); strcpy_P(hMsg, FPSTR("STARTTLS\r\n")); - ssl_client->_debugCallback(FPSTR("INFO: send STARTTLS protocol command")); + if (ssl_client->_debugCallback) + ssl_client->_debugCallback(FPSTR("INFO: send STARTTLS protocol command")); ret = lwip_write(ssl_client->socket, hMsg, strlen(hMsg)); if (ret < 0) diff --git a/src/ssl_client32.h b/src/ssl_client32.h index 218fdc9..4e7255b 100644 --- a/src/ssl_client32.h +++ b/src/ssl_client32.h @@ -1,5 +1,5 @@ /* - *Customized ssl_client.h to support STARTTLS protocol, version 1.0.1 + *Customized ssl_client.h to support STARTTLS protocol, version 1.0.2 * * The MIT License (MIT) * Copyright (c) 2019 K. Suwatchai (Mobizt)