From 811b132aa38d7e4273290905e0304c847f701fa7 Mon Sep 17 00:00:00 2001 From: philippe44 Date: Mon, 1 Jul 2019 14:41:28 -0700 Subject: [PATCH] aac incorrect synchro at the beginnign of a block locks the decoder --- components/squeezelite/helix-aac.c | 5 +++-- components/squeezelite/output_i2s.c | 5 ++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/components/squeezelite/helix-aac.c b/components/squeezelite/helix-aac.c index a9642b71..ef5d1b0e 100644 --- a/components/squeezelite/helix-aac.c +++ b/components/squeezelite/helix-aac.c @@ -370,8 +370,8 @@ static decode_state helixaac_decode(void) { channels = info.nChans; samplerate = info.sampRateOut; found = 1; - } - + } else if (n == 0) n++; + HAAC(a, FlushCodec, a->hAac); bytes_total -= n; @@ -412,6 +412,7 @@ static decode_state helixaac_decode(void) { // not finished header parsing come back next time UNLOCK_S; + LOG_INFO("header not found yet"); return DECODE_RUNNING; } } diff --git a/components/squeezelite/output_i2s.c b/components/squeezelite/output_i2s.c index 18dbafcf..e95b43d5 100644 --- a/components/squeezelite/output_i2s.c +++ b/components/squeezelite/output_i2s.c @@ -280,9 +280,8 @@ static void *output_thread_i2s() { SET_MIN_MAX( TIME_MEASUREMENT_GET(timer_start),i2s_time); frames = 0; - } else { - LOG_WARN("no frame returned %d", output.state); - } + } + } return 0;