Skip to content

Commit 3c9cb73

Browse files
committed
Allow other ESP debug port class types
... by casting to void pointers before comparison to avoid compile error (cherry picked from commit 3a69676)
1 parent 614f7c3 commit 3c9cb73

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cores/esp8266/HardwareSerial.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ void HardwareSerial::begin(unsigned long baud, SerialConfig config, SerialMode m
4040
end();
4141
_uart = uart_init(_uart_nr, baud, (int) config, (int) mode, tx_pin, _rx_size);
4242
#if defined(DEBUG_ESP_PORT) && !defined(NDEBUG)
43-
if (this == &DEBUG_ESP_PORT)
43+
if (static_cast<void*>(this) == static_cast<void*>(&DEBUG_ESP_PORT))
4444
{
4545
setDebugOutput(true);
4646
println();

0 commit comments

Comments
 (0)