audioconvert: check return value of pod parse

This commit is contained in:
Wim Taymans 2023-03-16 12:33:08 +01:00
parent 98a214891d
commit 689184a5e7

View file

@ -919,8 +919,8 @@ static int apply_props(struct impl *this, const struct spa_pod *param)
}
break;
case SPA_PROP_rate:
spa_pod_get_double(&prop->value, &p->rate);
if (!this->rate_adjust && p->rate != 1.0) {
if (spa_pod_get_double(&prop->value, &p->rate) == 0 &&
!this->rate_adjust && p->rate != 1.0) {
this->rate_adjust = true;
spa_log_info(this->log, "%p: activating adaptive resampler",
this);