mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
alsa: clear port before adding to free list
If we clear the port after adding, we will destroy the links into the list and cause crashes later.
This commit is contained in:
parent
02aee17cc3
commit
c9c7552fed
1 changed files with 1 additions and 1 deletions
|
|
@ -389,11 +389,11 @@ static void free_port(struct seq_state *state, struct seq_stream *stream, struct
|
|||
{
|
||||
stream->ports[port->id] = NULL;
|
||||
spa_list_remove(&port->link);
|
||||
spa_list_append(&state->free_list, &port->link);
|
||||
|
||||
spa_node_emit_port_info(&state->hooks,
|
||||
port->direction, port->id, NULL);
|
||||
spa_zero(*port);
|
||||
spa_list_append(&state->free_list, &port->link);
|
||||
}
|
||||
|
||||
static void init_port(struct seq_state *state, struct seq_port *port, const snd_seq_addr_t *addr,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue