Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] RECEIVE_MAXIMUM, TOPIC_ALIAS should be unsignedShort #1043

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -470,11 +470,11 @@ public void decodeProperties(DataInputStream dis) throws IOException, MqttExcept
} else if (identifier == REASON_STRING_IDENTIFIER) {
reasonString = MqttDataTypes.decodeUTF8(inputStream);
} else if (identifier == RECEIVE_MAXIMUM_IDENTIFIER) {
receiveMaximum = (int) inputStream.readShort();
receiveMaximum = inputStream.readUnsignedShort();
} else if (identifier == TOPIC_ALIAS_MAXIMUM_IDENTIFIER) {
topicAliasMaximum = (int) inputStream.readShort();
topicAliasMaximum = inputStream.readUnsignedShort();
} else if (identifier == TOPIC_ALIAS_IDENTIFIER) {
topicAlias = (int) inputStream.readShort();
topicAlias = inputStream.readUnsignedShort();
} else if (identifier == MAXIMUM_QOS_IDENTIFIER) {
maximumQoS = inputStream.read();
} else if (identifier == RETAIN_AVAILABLE_IDENTIFIER) {
Expand Down