@@ -448,17 +448,17 @@ void MqttClient::poll()
448
448
if ((b & 0x80 ) == 0 ) { // length done
449
449
bool malformedResponse = false ;
450
450
451
- if (_rxType == MQTT_CONNACK ||
451
+ if (_rxType == MQTT_CONNACK ||
452
452
_rxType == MQTT_PUBACK ||
453
- _rxType == MQTT_PUBREC ||
453
+ _rxType == MQTT_PUBREC ||
454
454
_rxType == MQTT_PUBCOMP ||
455
455
_rxType == MQTT_UNSUBACK) {
456
456
malformedResponse = (_rxFlags != 0x00 || _rxLength != 2 );
457
457
} else if (_rxType == MQTT_PUBLISH) {
458
458
malformedResponse = ((_rxFlags & 0x06 ) == 0x06 );
459
459
} else if (_rxType == MQTT_PUBREL) {
460
460
malformedResponse = (_rxFlags != 0x02 || _rxLength != 2 );
461
- } else if (_rxType == MQTT_SUBACK) {
461
+ } else if (_rxType == MQTT_SUBACK) {
462
462
malformedResponse = (_rxFlags != 0x00 || _rxLength != 3 );
463
463
} else if (_rxType == MQTT_PINGRESP) {
464
464
malformedResponse = (_rxFlags != 0x00 || _rxLength != 0 );
@@ -531,7 +531,7 @@ void MqttClient::poll()
531
531
if (_rxMessageIndex == 2 ) {
532
532
_rxMessageTopicLength = (_rxMessageBuffer[0 ] << 8 ) | _rxMessageBuffer[1 ];
533
533
_rxLength -= 2 ;
534
-
534
+
535
535
_rxMessageTopic = " " ;
536
536
_rxMessageTopic.reserve (_rxMessageTopicLength);
537
537
@@ -722,7 +722,7 @@ int MqttClient::read(uint8_t *buf, size_t size)
722
722
723
723
if (b == -1 ) {
724
724
break ;
725
- }
725
+ }
726
726
727
727
result++;
728
728
*buf++ = b;
@@ -819,7 +819,7 @@ void MqttClient::setTxPayloadSize(unsigned short size)
819
819
_txPayloadBuffer = NULL ;
820
820
_txPayloadBufferIndex = 0 ;
821
821
}
822
-
822
+
823
823
_tx_payload_buffer_size = size;
824
824
}
825
825
0 commit comments