From 4ad31c7857a5208b22aca8829355dea6357f1060 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20G=C3=A4hwiler?= Date: Thu, 22 Mar 2018 21:18:41 +0100 Subject: [PATCH] clarified multi threaded application usage --- include/lwmqtt.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/include/lwmqtt.h b/include/lwmqtt.h index ec1ca55..7585590 100644 --- a/include/lwmqtt.h +++ b/include/lwmqtt.h @@ -345,11 +345,12 @@ lwmqtt_err_t lwmqtt_disconnect(lwmqtt_client_t *client, uint32_t timeout); /** * Will yield control to the client and receive incoming packets from the network. * - * Applications may peek on the network if there is data available to read before calling yield and potentially block - * until the timeout is reached. Furthermore, applications may specify the amount of bytes available to read in order - * to constrain the yield to only receive packets that are already inflight. + * Single-threaded applications may peek on the network and assess if data is available to read before calling yield and + * potentially block until the timeout is reached. Multi-threaded applications may select on the socket and block until + * data is available and then yield to the client if data is available. All applications may specify the amount of bytes + * available to read in order to constrain the yield to only receive packets that are already in-flight. * - * If no availability data is given the yield will return after one packet has been successfully read or the deadline + * If no availability info is given the yield will return after one packet has been successfully read or the deadline * has been reached but no single bytes has been received. * * Note: The message callback might be called with incoming messages as part of this call.