Commit f5c677fe42d2cbf4a85101503b36d97353e7612d

Authored by Wiebe Cazemier
1 parent d541986e

Fix bug where first_byte and bites[0] aren't consistent

Showing 1 changed file with 1 additions and 0 deletions
mqttpacket.cpp
... ... @@ -481,6 +481,7 @@ void MqttPacket::handlePublish()
481 481 // Set dup flag to 0, because that must not be propagated [MQTT-3.3.1-3].
482 482 // Existing subscribers don't get retain=1. [MQTT-3.3.1-9]
483 483 bites[0] &= 0b11110110;
  484 + first_byte = bites[0];
484 485  
485 486 // For the existing clients, we can just write the same packet back out, with our small alterations.
486 487 sender->getThreadData()->getSubscriptionStore()->queuePacketAtSubscribers(*subtopics, *this);
... ...