paho.mqtt.java
paho.mqtt.java copied to clipboard
Stack Overflow on v5 subscribe()
Hi there,
Just trying out the v5 client for the first time. Ran into a stack overflow bug almost immediately. It's on line 525 of MqttClient:
public IMqttToken subscribe(String[] topicFilters, int[] qos, IMqttMessageListener[] messageListeners)
throws MqttException {
return this.subscribe(topicFilters, qos, messageListeners);
}
Thanks.
I think this caused because this function calls itself. And therefor gets in an infinite recursive loop. I worked around it, by using the subscribe function on line 528.
Looks like a fix is already in pull request. https://github.com/eclipse/paho.mqtt.java/pull/899
When will this bug going to be fixed? We are facing this issue and therefore can not use the paho mqtt v5 client.