eclipse-paho / eclipse-paho/paho.mqtt.java

ClientComms.close(true) doesn't work

Open
#641 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
2.3k
Forks
919
PR merge metrics
No merged PRs in 30d

Description

Please fill out the form below before submitting, thank you!

- [ ] Bug exists Release Version 1.2.0 ( Master Branch)
- [ ] Bug exists in MQTTv3 Client on Snapshot Version 1.2.1-SNAPSHOT (Develop Branch)
- [ ] Bug exists in MQTTv5 Client on Snapshot Version 1.2.1-SNAPSHOT (Develop Branch)

I don't fill out the form because the branches and releases obviously are not up-to date. The bug exists in 1.2.0 and 1.2.1.

ClientComms.close(boolean force) doesn't work correctly when called with force=true.
There are apperently missing parenthesis in l. 230:
```
if (!isDisconnected() || force) { // should be (!(isDisconnected() || force)) or better (!isDisconnected() && !force)
//@TRACE 224=failed: not disconnected
log.fine(CLASS_NAME, methodName, "224");
...
}
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.