From c7a0a50a7ecd3b8df0ae8b513c9410fcb6458513 Mon Sep 17 00:00:00 2001 From: Jean-Roland Date: Wed, 28 Feb 2024 17:31:41 +0100 Subject: [PATCH] fix: include first mapping entry in lookup --- src/transport/raweth/tx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/transport/raweth/tx.c b/src/transport/raweth/tx.c index 56af858a7..5c82b84ac 100644 --- a/src/transport/raweth/tx.c +++ b/src/transport/raweth/tx.c @@ -37,7 +37,7 @@ static void _zp_raweth_unlock_tx_mutex(_z_transport_multicast_t *ztm) { _ZP_UNUS #endif static int _zp_raweth_find_map_entry(const _z_keyexpr_t *keyexpr, _z_raweth_socket_t *sock) { - for (int i = 1; i < _zp_raweth_mapping_array_len(&sock->_mapping); i++) { + for (int i = 0; i < _zp_raweth_mapping_array_len(&sock->_mapping); i++) { // Find matching keyexpr _zp_raweth_mapping_entry_t *entry = _zp_raweth_mapping_array_get(&sock->_mapping, i); if (zp_keyexpr_intersect_null_terminated(keyexpr->_suffix, entry->_keyexpr._suffix) != _Z_RES_OK) {