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

Calling disconnect twice results in crash #561

Closed
fabmazz opened this issue Feb 15, 2024 · 1 comment · Fixed by #563
Closed

Calling disconnect twice results in crash #561

fabmazz opened this issue Feb 15, 2024 · 1 comment · Fixed by #563

Comments

@fabmazz
Copy link
Contributor

fabmazz commented Feb 15, 2024

I have a code that calls client.disconnect() when certain conditions are met.

However, I also want to disconnect when closing the fragment.

When I try to call client.disconnect() again, after the first one, the library crashes:

Process: it.reyboz.bustorino.debug, PID: 26148
java.lang.IllegalArgumentException: Invalid ClientHandle >wss://mapi.5t.torino.it:443/scre:mqtt-explorer-f173f581:it.reyboz.bustorino.debug<
at info.mqtt.android.service.MqttService.getConnection(MqttService.kt:492)
at info.mqtt.android.service.MqttService.disconnect(MqttService.kt:332)
at info.mqtt.android.service.MqttAndroidClient.disconnect(MqttAndroidClient.kt:284)
@hannesa2
Copy link
Owner

#563

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants