Fix cleanup

This commit is contained in:
Wim Taymans 2019-05-10 11:15:48 +02:00
parent 41ab051b68
commit 1a7fcaf9c6
3 changed files with 5 additions and 3 deletions

View file

@ -633,8 +633,9 @@ static int port_set_format(struct spa_node *node,
if (port->have_format) {
port->have_format = false;
clear_buffers(this, port);
if (this->mix.process)
channelmix_free(&this->mix);
}
channelmix_free(&this->mix);
} else {
struct spa_audio_info info = { 0 };

View file

@ -553,7 +553,7 @@ static int port_set_format(struct spa_node *node,
if (port->have_format) {
port->have_format = false;
clear_buffers(this, port);
if (this->conv.free)
if (this->conv.process)
convert_free(&this->conv);
}
} else {

View file

@ -653,7 +653,8 @@ client_node_port_set_param(void *object,
port = pw_node_find_port(data->node, direction, port_id);
if (port == NULL) {
res = -EINVAL;
pw_proxy_error(proxy, res, "unknown port");
pw_proxy_error(proxy, res, "unknown %s port %d",
direction == SPA_DIRECTION_INPUT ? "input" : "output", port_id);
goto done;
}