From 715ee3d2a25dc89a03d6fea0e8dde91b8bf219e4 Mon Sep 17 00:00:00 2001 From: "Lin.Sun" Date: Wed, 8 Jul 2020 17:22:46 +0800 Subject: [PATCH] [mod_silk] switch_silk_decode: Fix invalid condition for return code from switch_jb_peek_frame(). --- src/mod/codecs/mod_silk/mod_silk.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mod/codecs/mod_silk/mod_silk.c b/src/mod/codecs/mod_silk/mod_silk.c index b41b8510eb..507309a362 100644 --- a/src/mod/codecs/mod_silk/mod_silk.c +++ b/src/mod/codecs/mod_silk/mod_silk.c @@ -352,7 +352,7 @@ static switch_status_t switch_silk_decode(switch_codec_t *codec, frame.buflen = sizeof(buf); for (i = 1; i <= MAX_LBRR_DELAY; i++) { - if (switch_jb_peek_frame(jb, codec->cur_frame->timestamp, 0, (uint16_t)i, &frame)) { + if (switch_jb_peek_frame(jb, codec->cur_frame->timestamp, 0, (uint16_t)i, &frame) == SWITCH_STATUS_SUCCESS) { SKP_Silk_SDK_search_for_LBRR(frame.data, (const int)frame.datalen, i, (SKP_uint8*) &context->recbuff, &context->reclen); if (context->reclen) {