There is a behavior, that I did not expect. Not sure whether this is really a bug, or intended behavior.
I am on version 2.0.11.
This is what I do on client side, in order to connect to mosquitto broker:
mosquitto_new
mosquitto_int_option
mosquitto_connect_v5_callback_set
mosquitto_disconnect_v5_callback_set
mosquitto_publish_v5_callback_set
mosquitto_message_v5_callback_set
mosquitto_subscribe_v5_callback_set
mosquitto_unsubscribe_v5_callback_set
mosquitto_log_callback_set
mosquitto_loop_start
mosquitto_connect_async
Then I see a thread running, handling the I/O and the client is properly connected to the broker.
I do then call mosquitto_disconnect, which closes the connection.
Then calling mosquitto_connect_async again, I would expect the connection to be established again.
But what I see in Wireshark is, that it opens the TCP connection but does not send any MQTT package.
It provides the log "Client sending CONNECT" but does not actually send the CONNECT package.
Even if I call mosquitto_loop_start before mosquitto_connect_async it makes no difference, the thread is not started again.
Is my expectation correct?
There is a behavior, that I did not expect. Not sure whether this is really a bug, or intended behavior.
I am on version 2.0.11.
This is what I do on client side, in order to connect to mosquitto broker:
Then I see a thread running, handling the I/O and the client is properly connected to the broker.
I do then call
mosquitto_disconnect, which closes the connection.Then calling
mosquitto_connect_asyncagain, I would expect the connection to be established again.But what I see in Wireshark is, that it opens the TCP connection but does not send any MQTT package.
It provides the log "Client sending CONNECT" but does not actually send the CONNECT package.
Even if I call
mosquitto_loop_startbeforemosquitto_connect_asyncit makes no difference, the thread is not started again.Is my expectation correct?