client-stream: there is always and adapter

This commit is contained in:
Wim Taymans 2018-10-04 16:36:09 +02:00
parent 8f1ebe0c7e
commit f81588f439

View file

@ -193,7 +193,6 @@ impl_node_get_n_ports(struct spa_node *node,
this = SPA_CONTAINER_OF(node, struct node, node);
impl = this->impl;
if (impl->adapter) {
spa_node_get_n_ports(impl->adapter,
n_input_ports,
max_input_ports,
@ -211,23 +210,6 @@ impl_node_get_n_ports(struct spa_node *node,
if (max_output_ports)
*max_output_ports = 0;
}
} else {
uint32_t n_inputs = 0, n_outputs = 0;
if (impl->direction == SPA_DIRECTION_OUTPUT)
n_outputs++;
else
n_inputs++;
if (n_input_ports)
*n_input_ports = n_inputs;
if (max_input_ports)
*max_input_ports = n_inputs;
if (n_output_ports)
*n_output_ports = n_outputs;
if (max_output_ports)
*max_output_ports = n_outputs;
}
return 0;
}