File tree Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -257,6 +257,12 @@ int __cheri_compartment("MQTT") mqtt_unsubscribe(Timeout *t,
257257 * Fetch ACK and PUBLISH notifications on a given MQTT connection, and keep
258258 * the connection alive.
259259 *
260+ * This function will invoke the callbacks passed to `mqtt_connect`. The
261+ * connection object is protected by a recursive mutex, so these callbacks can
262+ * call additional publish and subscribe functions. If doing so, care must be
263+ * taken to ensure that the buffer is not exhausted. Calling `mqtt_run` from a
264+ * callback is not supported.
265+ *
260266 * The return value is zero if notifications were successfully fetched, or a
261267 * negative error code.
262268 *
Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ namespace
6868 NetworkContext_t networkContext;
6969
7070 // Lock on which the whole public API synchronizes.
71- FlagLockPriorityInherited lock;
71+ RecursiveMutex lock;
7272
7373 /* *
7474 * Constructor of the CHERIoT MQTT context object. We keep
You can’t perform that action at this time.
0 commit comments