blocking loop

This commit is contained in:
leo 2023-07-10 21:11:41 +02:00
parent 996bed526a
commit 258c1a1faf
Signed by: leo
GPG Key ID: 0DD993BFB2B307DB

View File

@ -136,7 +136,7 @@ int main(int argc, char *argv[])
return 1;
}
//Start a thread, and call mosquitto? Loop() continuously in the thread to process network information
int loop = mosquitto_loop_start(mosq);
int loop = mosquitto_loop_forever(mosq, -1, 1);
if(loop != MOSQ_ERR_SUCCESS)
{
fprintf(stderr, "ERROR: failed to create mosquitto loop");