Open gcog33 opened 1 year ago
In the file pubsubclient/src/PubSubClient.cpp In line 475 there is a small bug:
boolean PubSubClient::publish_P(const char* topic, const char* payload, boolean retained) { return publish_P(topic, (const uint8_t*)payload, payload ? strnlen(payload, this->bufferSize) : 0, retained); }
The function strnlen must be replaced by strnlen_P because the payload is in program memory (PROGMEM)
In the file pubsubclient/src/PubSubClient.cpp In line 475 there is a small bug:
The function strnlen must be replaced by strnlen_P because the payload is in program memory (PROGMEM)