summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-04-05 23:41:31 +0200
committerwm4 <wm4@nowhere>2013-04-13 04:21:29 +0200
commit0d939a6847b139a29aaa21bd0b73d5fa28c6fb03 (patch)
treeeaf2f9d881688c6b71699508670eac4ca116b58c
parentfd6302631a537f198ba60ae29c8818111881b0b1 (diff)
downloadmpv-0d939a6847b139a29aaa21bd0b73d5fa28c6fb03.tar.bz2
mpv-0d939a6847b139a29aaa21bd0b73d5fa28c6fb03.tar.xz
af: fix negotiation endless loop
Yeah... ok. Can be reproduced by having AF_CONTROL_CHANNELS not really set the correct channel map.
-rw-r--r--audio/filter/af.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/audio/filter/af.c b/audio/filter/af.c
index 51dbd3fa77..9f534ad2fb 100644
--- a/audio/filter/af.c
+++ b/audio/filter/af.c
@@ -443,8 +443,8 @@ int af_reinit(struct af_stream *s)
// filter which needs no initialization.
struct af_instance *af = s->first->next;
int retry = 0;
- while (af && retry < 5) {
- if (retry >= 5)
+ while (af) {
+ if (retry >= 20)
goto negotiate_error;
// Check if this is the first filter
@@ -492,7 +492,6 @@ int af_reinit(struct af_stream *s)
af_print_filter_chain(s, af);
return AF_ERROR;
}
- retry = 0;
}
af_print_filter_chain(s, NULL);