mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-31 22:25:38 -04:00
protocol-native: check for NULL strings
SPA_POD_String allows NULL strings, so check for them.
This commit is contained in:
parent
adb3a55703
commit
c54fdb76f8
1 changed files with 2 additions and 0 deletions
|
|
@ -33,6 +33,8 @@ static inline int parse_item(struct spa_pod_parser *prs, struct spa_dict_item *i
|
|||
SPA_POD_String(&item->value),
|
||||
NULL)) < 0)
|
||||
return res;
|
||||
if (item->key == NULL || item->value == NULL)
|
||||
return -EINVAL;
|
||||
if (spa_strstartswith(item->value, "pointer:"))
|
||||
item->value = "";
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue