Skip to content

Commit 0049090

Browse files
authored
comments in ClientContext::connect() (#7961)
* add comment
1 parent bde6ab1 commit 0049090

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

libraries/ESP8266WiFi/src/include/ClientContext.h

+3
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,9 @@ class ClientContext
131131

132132
int connect(ip_addr_t* addr, uint16_t port)
133133
{
134+
// note: not using `const ip_addr_t* addr` because
135+
// - `ip6_addr_assign_zone()` below modifies `*addr`
136+
// - caller's parameter `WiFiClient::connect` is a local copy
134137
#if LWIP_IPV6
135138
// Set zone so that link local addresses use the default interface
136139
if (IP_IS_V6(addr) && ip6_addr_lacks_zone(ip_2_ip6(addr), IP6_UNKNOWN)) {

0 commit comments

Comments
 (0)