MQTT v5.0/UNSUBACK includes a payload conformed
by a list of reason codes. There is no length
field for this payload, so it must be computed
as the difference between the full message size
and the current offset.
Change-Id: Ibf7ef4131408e26e2389c3ab89107c22c16412a1
Signed-off-by: Flavio Santes <flavio.santes@1byt3.com>
Reviewed-on: https://code.wireshark.org/review/24337
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
if (mqtt->runtime_proto_version == MQTT_PROTO_V50)
{
offset += dissect_mqtt_properties(tvb, mqtt_tree, offset);
+
+ while (offset < tvb_reported_length(tvb))
+ {
+ proto_tree_add_item(mqtt_tree, hf_mqtt_reason_code, tvb, offset, 1, ENC_BIG_ENDIAN);
+ offset += 1;
+ }
}
break;