提交 5fcb9347 编写于 作者: J Johan Hedberg 提交者: Marcel Holtmann

Bluetooth: Remove redundant check for remote_key_dist

In the smp_cmd_sign_info() function the SMP_DIST_SIGN bit is explicitly
cleared early on in the function. This means that there's no need to
check for it again before calling smp_distribute_keys().
Signed-off-by: NJohan Hedberg <johan.hedberg@intel.com>
Signed-off-by: NMarcel Holtmann <marcel@holtmann.org>
上级 22f433dc
...@@ -1168,7 +1168,6 @@ static int smp_cmd_sign_info(struct l2cap_conn *conn, struct sk_buff *skb) ...@@ -1168,7 +1168,6 @@ static int smp_cmd_sign_info(struct l2cap_conn *conn, struct sk_buff *skb)
memcpy(csrk->val, rp->csrk, sizeof(csrk->val)); memcpy(csrk->val, rp->csrk, sizeof(csrk->val));
} }
smp->csrk = csrk; smp->csrk = csrk;
if (!(smp->remote_key_dist & SMP_DIST_SIGN))
smp_distribute_keys(conn); smp_distribute_keys(conn);
hci_dev_unlock(hdev); hci_dev_unlock(hdev);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册