diff --git a/src/MQTT/Client.cpp b/src/MQTT/Client.cpp index 7d3e75f5..9d698acf 100644 --- a/src/MQTT/Client.cpp +++ b/src/MQTT/Client.cpp @@ -547,6 +547,10 @@ void Client::onMessageReceived(const QMQTT::Message &message) if (topic() != mtopic) return; - // Let IO manager process incoming data + // Add EOL character + if (!mpayld.endsWith('\n')) + mpayld.append('\n'); + + // Let IO manager process incoming data IO::Manager::getInstance()->processPayload(mpayld); }