summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorFelicia Lim <flim@google.com>2019-12-02 16:37:14 -0800
committerFelicia Lim <flim@google.com>2019-12-03 09:32:43 -0800
commit8493bf50892be0e902a354444747e6d14f2a6a10 (patch)
tree16f0a8879afdfc18b6ba213e7133588a7b431e49 /src
parentcd529edb3363b0be6aebdefa09c4188629f45e2c (diff)
downloadopus-8493bf50892be0e902a354444747e6d14f2a6a10.tar.gz
Don't update null data pointer after each multistream decoder
The data pointer could be null in the case of DTX or packet loss.
Diffstat (limited to 'src')
-rw-r--r--src/opus_multistream_decoder.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/opus_multistream_decoder.c b/src/opus_multistream_decoder.c
index 0018517a..a2837c35 100644
--- a/src/opus_multistream_decoder.c
+++ b/src/opus_multistream_decoder.c
@@ -251,8 +251,11 @@ int opus_multistream_decode_native(
}
packet_offset = 0;
ret = opus_decode_native(dec, data, len, buf, frame_size, decode_fec, s!=st->layout.nb_streams-1, &packet_offset, soft_clip);
- data += packet_offset;
- len -= packet_offset;
+ if (!do_plc)
+ {
+ data += packet_offset;
+ len -= packet_offset;
+ }
if (ret <= 0)
{
RESTORE_STACK;