Skip to content
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
2 changes: 2 additions & 0 deletions src/MQTTAsyncUtils.c
Original file line number Diff line number Diff line change
Expand Up @@ -2436,6 +2436,8 @@ static void MQTTAsync_stop(void)
{
int count = 0;
MQTTAsync_tostop = 1;
Socket_interrupt(); /* wake receive thread from poll() */
Thread_signal_evt(send_evt); /* wake send thread from Thread_wait_evt */
while ((sendThread_state != STOPPED || receiveThread_state != STOPPED) && MQTTAsync_tostop != 0 && ++count < 100)
{
MQTTAsync_unlock_mutex(mqttasync_mutex);
Expand Down
Loading