mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2026-05-17 21:41:45 -04:00
modules: handle some more allocation errors
This commit is contained in:
parent
379b4a8747
commit
9946f5ec77
4 changed files with 30 additions and 0 deletions
|
|
@ -353,6 +353,8 @@ static int rule_matched(void *data, const char *location, const char *action,
|
|||
i->matched = true;
|
||||
if (spa_streq(action, "create-stream")) {
|
||||
struct pw_properties *p = pw_properties_copy(i->props);
|
||||
if (p == NULL)
|
||||
return -errno;
|
||||
pw_properties_update_string(p, str, len);
|
||||
create_stream(i->stream, p);
|
||||
}
|
||||
|
|
@ -373,6 +375,8 @@ do_setup_stream(struct spa_loop *loop,
|
|||
uint16_t port = 0;
|
||||
|
||||
props = pw_properties_copy(impl->stream_props);
|
||||
if (props == NULL)
|
||||
return -errno;
|
||||
|
||||
pw_net_get_ip(&s->sa, addr, sizeof(addr), NULL, &port);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue