@@ -994,6 +994,7 @@ static inline int32_t ack_timeout(struct seg_rx *rx)
994
994
int bt_mesh_ctl_send (struct bt_mesh_net_tx * tx , uint8_t ctl_op , void * data ,
995
995
size_t data_len , const struct bt_mesh_send_cb * cb , void * cb_data )
996
996
{
997
+ int err ;
997
998
struct os_mbuf * buf = NET_BUF_SIMPLE (data_len );
998
999
999
1000
net_buf_simple_init_with_data (buf , data , data_len );
@@ -1022,11 +1023,12 @@ int bt_mesh_ctl_send(struct bt_mesh_net_tx *tx, uint8_t ctl_op, void *data,
1022
1023
BT_DBG ("len %zu: %s" , data_len , bt_hex (data , data_len ));
1023
1024
1024
1025
if (tx -> ctx -> send_rel ) {
1025
- return send_seg (tx , buf , cb , cb_data , & ctl_op );
1026
+ err = send_seg (tx , buf , cb , cb_data , & ctl_op );
1026
1027
} else {
1027
- return send_unseg (tx , buf , cb , cb_data , & ctl_op );
1028
+ err = send_unseg (tx , buf , cb , cb_data , & ctl_op );
1028
1029
}
1029
1030
os_mbuf_free_chain (buf );
1031
+ return err ;
1030
1032
}
1031
1033
1032
1034
static int send_ack (struct bt_mesh_subnet * sub , uint16_t src , uint16_t dst ,
0 commit comments