Skip to contentSkip to conversation

mesh: Fix adding virtual subscription to a vendor model

PATCH Applied Inga Stotland 2 participants 2 messages Apr 29, 2020 – Apr 30, 2020 Bluetooth drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mesh: Fix adding virtual subscription to a vendor model

This fixes a case when a configuration server receives a virtual subscription add/overwrite command targeting a vendor model. Correctly set "vendor" argument before trying to save the updated subscrition to configuration file.

---
 mesh/cfgmod-server.c | 1 +
 1 file changed, 1 insertion(+)
mesh/cfgmod-server.c +1 -0
index 856eb6b27..94825ed0e 100644
@@ -358,6 +358,7 @@ static void config_sub_set(struct mesh_node *node, uint16_t net_idx,
 	case 22:
 		if (!virt)
 			return;
+		vendor = true;
 		mod_id = l_get_le16(pkt + 18) << 16;
 		mod_id |= l_get_le16(pkt + 20);
 		break;
Signature · 1 line
2.21.1
Applied
#1 lore raw

Applied

Quoted 20 lines · Inga Stotland

This fixes a case when a configuration server receives a virtual subscription add/overwrite command targeting a vendor model. Correctly set "vendor" argument before trying to save the updated subscrition to configuration file.

---
 mesh/cfgmod-server.c | 1 +
 1 file changed, 1 insertion(+)
mesh/cfgmod-server.c +1 -0
index 856eb6b27..94825ed0e 100644
@@ -358,6 +358,7 @@ static void config_sub_set(struct mesh_node *node, uint16_t net_idx,
 	case 22:
 		if (!virt)
 			return;
+		vendor = true;
 		mod_id = l_get_le16(pkt + 18) << 16;
 		mod_id |= l_get_le16(pkt + 20);
 		break;