projects
/
platform
/
upstream
/
bluez.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0680e67
)
client/player: Fix scan-build warning
author
Luiz Augusto von Dentz
<luiz.von.dentz@intel.com>
Mon, 21 Nov 2022 21:01:46 +0000
(13:01 -0800)
committer
Ayush Garg
<ayush.garg@samsung.com>
Fri, 5 Jan 2024 10:11:34 +0000
(15:41 +0530)
This fixes the following warning:
client/player.c:1775:25: warning: Dereference of null pointer
[core.NullDereference]
iov_append(&cfg->caps, preset->data.iov_base, preset->data.iov_len);
^~~~~~~~~~~~~~~~~~~~~
client/player.c
patch
|
blob
|
history
diff --git
a/client/player.c
b/client/player.c
index
996da26
..
43934cd
100644
(file)
--- a/
client/player.c
+++ b/
client/player.c
@@
-1744,6
+1744,9
@@
static DBusMessage *endpoint_select_properties_reply(struct endpoint *ep,
DBusMessageIter iter;
struct endpoint_config *cfg;
+ if (!preset)
+ return NULL;
+
reply = dbus_message_new_method_return(msg);
if (!reply)
return NULL;