mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
adapter: improve format parsing some more
This commit is contained in:
parent
c5a7f30a68
commit
9fb14be4e3
2 changed files with 10 additions and 10 deletions
|
|
@ -748,13 +748,10 @@ static int impl_node_set_param(void *object, uint32_t id, uint32_t flags,
|
|||
if (param == NULL)
|
||||
return -EINVAL;
|
||||
|
||||
if ((res = spa_format_parse(param, &info.media_type, &info.media_subtype)) < 0)
|
||||
return res;
|
||||
if (info.media_type != SPA_MEDIA_TYPE_video ||
|
||||
info.media_subtype != SPA_MEDIA_SUBTYPE_raw)
|
||||
return -EINVAL;
|
||||
if (spa_format_video_parse(param, &info) < 0)
|
||||
return -EINVAL;
|
||||
if (info.media_subtype != SPA_MEDIA_SUBTYPE_raw)
|
||||
return -EINVAL;
|
||||
|
||||
this->follower_current_format = info;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue