Bluetooth: Mesh: Fix resetting heartbeat subscription expiry properly
Set the value clearly to 0 instead of letting the old expiry time stay around. Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This commit is contained in:
parent
f1638e0a2b
commit
19c304086f
|
@ -2837,6 +2837,8 @@ static void heartbeat_sub_set(struct bt_mesh_model *model,
|
|||
|
||||
if (period_ms) {
|
||||
cfg->hb_sub.expiry = k_uptime_get() + period_ms;
|
||||
} else {
|
||||
cfg->hb_sub.expiry = 0;
|
||||
}
|
||||
|
||||
hb_sub_send_status(model, ctx, STATUS_SUCCESS);
|
||||
|
|
Loading…
Reference in a new issue