Skip to content

Commit

Permalink
Added the compilation fixes for the conversion errors for lower idf v…
Browse files Browse the repository at this point in the history
…ersions.
  • Loading branch information
shripad621git committed Mar 22, 2024
1 parent 6f57a17 commit de580ae
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/platform/ESP32/ConnectivityManagerImpl_WiFi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1119,8 +1119,8 @@ void ConnectivityManagerImpl::OnStationIPv6AddressAvailable(const ip_event_got_i
{
uint8_t dig1 = (station_mac[i] & 0xF0) >> 4;
uint8_t dig2 = station_mac[i] & 0x0F;
station_mac_str[2 * i] = dig1 > 9 ? ('A' + dig1 - 0xA) : ('0' + dig1);
station_mac_str[2 * i + 1] = dig2 > 9 ? ('A' + dig2 - 0xA) : ('0' + dig2);
station_mac_str[2 * i] = static_cast<char>(dig1 > 9 ? ('A' + dig1 - 0xA) : ('0' + dig1));
station_mac_str[2 * i + 1] = static_cast<char>(dig2 > 9 ? ('A' + dig2 - 0xA) : ('0' + dig2));
}
if (sEndpointQueueFilter.SetMdnsHostName(chip::CharSpan(station_mac_str)) == CHIP_NO_ERROR)
{
Expand Down
2 changes: 1 addition & 1 deletion src/platform/ESP32/ESP32EndpointQueueFilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ class ESP32EndpointQueueFilter : public EndpointQueueFilter
{
if (hostNameLowerCase[i] <= 'F' && hostNameLowerCase[i] >= 'A')
{
hostNameLowerCase[i] = 'a' + hostNameLowerCase[i] - 'A';
hostNameLowerCase[i] = static_cast<uint8_t>('a' + hostNameLowerCase[i] - 'A');
}
}
return PayloadContains(payload, ByteSpan(mHostNameBuffer)) || PayloadContains(payload, ByteSpan(hostNameLowerCase));
Expand Down

0 comments on commit de580ae

Please sign in to comment.