Skip to content

Commit 2d9e767

Browse files
trygvisigrr
authored andcommitted
Fixing a few compiler warnings to allow compilation with -Wall -Wextra and -Werror. (esp8266#3153)
1 parent db4d3e0 commit 2d9e767

File tree

3 files changed

+2
-3
lines changed

3 files changed

+2
-3
lines changed

libraries/ESP8266HTTPClient/src/ESP8266HTTPClient.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,6 @@ bool HTTPClient::begin(String url)
132132
bool HTTPClient::beginInternal(String url, const char* expectedProtocol)
133133
{
134134
DEBUG_HTTPCLIENT("[HTTP-Client][begin] url: %s\n", url.c_str());
135-
bool hasPort = false;
136135
clear();
137136

138137
// check for : (http: or https:

libraries/ESP8266WiFi/src/WiFiClientSecure.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -601,7 +601,7 @@ bool WiFiClientSecure::loadPrivateKey(Stream& stream, size_t size)
601601
extern "C" int __ax_port_read(int fd, uint8_t* buffer, size_t count)
602602
{
603603
ClientContext* _client = SSLContext::getIOContext(fd);
604-
if (!_client || _client->state() != ESTABLISHED && !_client->getSize()) {
604+
if (!_client || (_client->state() != ESTABLISHED && !_client->getSize())) {
605605
errno = EIO;
606606
return -1;
607607
}

tools/sdk/lwip/include/lwip/debug.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363

6464
#ifndef LWIP_NOASSERT
6565
#define LWIP_ASSERT(message, assertion) do { if(!(assertion)) \
66-
LWIP_PLATFORM_ASSERT(message); } while(0)
66+
{ LWIP_PLATFORM_ASSERT(message); } } while(0)
6767
#else /* LWIP_NOASSERT */
6868
#define LWIP_ASSERT(message, assertion)
6969
#endif /* LWIP_NOASSERT */

0 commit comments

Comments
 (0)