Commit 0389a63
committed
Bluetooth: host: refactor bt_gatt_is_subscribed
Refactors `bt_gatt_is_subscribed` by changing a CHECKIF to an if
statement to avoid undefined behavior if CHECKIFs are "disabled".
Uses sizeof(a uint8_t) instead of 1 to avoid magic numbers.
Initializes `properties` to 0 to avoid undefined behavior.
Signed-off-by: Håvard Reierstad <[email protected]>1 parent 23fb3b7 commit 0389a63
1 file changed
+4
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3475 | 3475 | | |
3476 | 3476 | | |
3477 | 3477 | | |
3478 | | - | |
| 3478 | + | |
3479 | 3479 | | |
3480 | 3480 | | |
3481 | | - | |
| 3481 | + | |
3482 | 3482 | | |
3483 | 3483 | | |
3484 | 3484 | | |
3485 | 3485 | | |
3486 | | - | |
| 3486 | + | |
3487 | 3487 | | |
3488 | 3488 | | |
3489 | 3489 | | |
3490 | | - | |
| 3490 | + | |
3491 | 3491 | | |
3492 | 3492 | | |
3493 | 3493 | | |
| |||
0 commit comments