mirror of
https://github.com/apache/nuttx.git
synced 2026-05-28 20:08:15 +08:00
bluetooth: Move the lower half null check to common place
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
committed by
Brennan Ashton
parent
9103184722
commit
7df322c6be
@@ -75,7 +75,11 @@ int btuart_register(FAR const struct btuart_lowerhalf_s *lower)
|
||||
|
||||
wlinfo("lower %p\n", lower);
|
||||
|
||||
DEBUGASSERT(lower != NULL);
|
||||
if (lower == NULL)
|
||||
{
|
||||
wlerr("ERROR: btuart lower half is NULL\n");
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
/* Allocate a new instance of the upper half driver state structure */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user