diff --git a/src/transport/multicast/tx.c b/src/transport/multicast/tx.c index e3e0c9b71..3d5b18c0d 100644 --- a/src/transport/multicast/tx.c +++ b/src/transport/multicast/tx.c @@ -143,6 +143,9 @@ int8_t _z_multicast_send_n_msg(_z_session_t *zn, const _z_network_message_t *n_m } } } + + // Clear the buffer as it's no longer required + _z_wbuf_clear(&fbf); } } diff --git a/src/transport/unicast/tx.c b/src/transport/unicast/tx.c index 21694e1e9..f2ac6feee 100644 --- a/src/transport/unicast/tx.c +++ b/src/transport/unicast/tx.c @@ -152,6 +152,9 @@ int8_t _z_unicast_send_n_msg(_z_session_t *zn, const _z_network_message_t *n_msg } } } + + // Clear the buffer as it's no longer required + _z_wbuf_clear(&fbf); } }