Commit: 04cd5d2a97c887938ff53b621a4a4a6cc7eec967
Parent: 26bc1c9cd9dfe3877220173edd58f53c457b9d26
Author: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Committer: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Date: 2025-03-06 17:58:25
Tree: ea325422eb0f563365bb88c3d25a3f5da322a841

btdev: Fix scan-build warnings This fixes the following scan-build warnings: emulator/btdev.c:1126:10: warning: Although the value stored to 'conn' is used in the enclosing expression, the value is never actually read from 'conn' [deadcode.DeadStores] 1126 | while ((conn = queue_find(dev->conns, match_handle, | ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1127 | UINT_TO_PTR(handle)))) | ~~~~~~~~~~~~~~~~~~~~ emulator/btdev.c:1413:24: warning: Access to field 'link' results in a dereference of a null pointer (loaded from variable 'conn') [core.NullDereference] 1413 | pending_conn_del(dev, conn->link->dev); | ^~~~~~~~~~ emulator/btdev.c:1535:13: warning: Access to field 'dev' results in a dereference of a null pointer (loaded from variable 'conn') [core.NullDereference] 1535 | send_event(conn->dev, BT_HCI_EVT_AUTH_COMPLETE, &ev, sizeof(ev)); | ^~~~~~~~~

Diffstat

M emulator/btdev.c | 10 +++++- - - - -

1 files changed, 5 insertions(+), 5 deletions(-)

View Full Diff | Patch