summaryrefslogtreecommitdiffstats
path: root/media/libopus/src/opus.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
commit40a355a42d4a9444dc753c04c6608dade2f06a23 (patch)
tree871fc667d2de662f171103ce5ec067014ef85e61 /media/libopus/src/opus.c
parentAdding upstream version 124.0.1. (diff)
downloadfirefox-40a355a42d4a9444dc753c04c6608dade2f06a23.tar.xz
firefox-40a355a42d4a9444dc753c04c6608dade2f06a23.zip
Adding upstream version 125.0.1.upstream/125.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'media/libopus/src/opus.c')
-rw-r--r--media/libopus/src/opus.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/media/libopus/src/opus.c b/media/libopus/src/opus.c
index 538b5ea74e..816a4dd5fa 100644
--- a/media/libopus/src/opus.c
+++ b/media/libopus/src/opus.c
@@ -194,7 +194,8 @@ int opus_packet_get_samples_per_frame(const unsigned char *data,
int opus_packet_parse_impl(const unsigned char *data, opus_int32 len,
int self_delimited, unsigned char *out_toc,
const unsigned char *frames[48], opus_int16 size[48],
- int *payload_offset, opus_int32 *packet_offset)
+ int *payload_offset, opus_int32 *packet_offset,
+ const unsigned char **padding, opus_int32 *padding_len)
{
int i, bytes;
int count;
@@ -337,6 +338,11 @@ int opus_packet_parse_impl(const unsigned char *data, opus_int32 len,
data += size[i];
}
+ if (padding != NULL)
+ {
+ *padding = data;
+ *padding_len = pad;
+ }
if (packet_offset)
*packet_offset = pad+(opus_int32)(data-data0);
@@ -351,6 +357,6 @@ int opus_packet_parse(const unsigned char *data, opus_int32 len,
opus_int16 size[48], int *payload_offset)
{
return opus_packet_parse_impl(data, len, 0, out_toc,
- frames, size, payload_offset, NULL);
+ frames, size, payload_offset, NULL, NULL, NULL);
}