summaryrefslogtreecommitdiff
path: root/mesh
diff options
context:
space:
mode:
authorIsak Westin <isak.westin@hotmail.com>2022-06-30 09:29:19 +0200
committerBrian Gix <brian.gix@intel.com>2022-06-30 13:18:06 -0700
commitbe7ebf29b370d298290f6a4eceb31b1d9c94081c (patch)
treedec7dd3095a95d13a5453d9e1c5e633b0335dbe6 /mesh
parent1d6cfb8e625a944010956714c1802bc1e1fc6c4f (diff)
downloadbluez-be7ebf29b370d298290f6a4eceb31b1d9c94081c.tar.gz
mesh: Use correct net_id for received CTL messages
For received CTL mesh messages, the wrong network ID variable was passed to ctl_received. This patch changes to the correct variable. Also, changed type of net_key_id argument in ctl_received function to be consistent wich the whole call chain.
Diffstat (limited to 'mesh')
-rw-r--r--mesh/net.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mesh/net.c b/mesh/net.c
index 8ff3ef32e..e8e6d3a61 100644
--- a/mesh/net.c
+++ b/mesh/net.c
@@ -2028,7 +2028,7 @@ static bool seg_rxed(struct mesh_net *net, bool frnd, uint32_t iv_index,
return false;
}
-static bool ctl_received(struct mesh_net *net, uint16_t net_key_id,
+static bool ctl_received(struct mesh_net *net, uint32_t net_key_id,
uint32_t iv_index, uint8_t ttl,
uint32_t seq,
uint16_t src, uint16_t dst,
@@ -2347,7 +2347,7 @@ static enum _relay_advice packet_received(void *user_data,
net_seqZero,
l_get_be32(msg + 3));
} else {
- ctl_received(net, key_aid, iv_index, net_ttl,
+ ctl_received(net, net_key_id, iv_index, net_ttl,
net_seq, net_src, net_dst,
net_opcode, rssi, msg,
app_msg_len);