Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
5bd0343b
Commit
5bd0343b
authored
Oct 27, 2011
by
Justin Ruggles
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
flacdec: use av_get_bytes_per_sample() to get sample size
parent
272fcc32
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
flacdec.c
libavcodec/flacdec.c
+2
-1
No files found.
libavcodec/flacdec.c
View file @
5bd0343b
...
...
@@ -587,7 +587,8 @@ static int flac_decode_frame(AVCodecContext *avctx,
bytes_read
=
(
get_bits_count
(
&
s
->
gb
)
+
7
)
/
8
;
/* check if allocated data size is large enough for output */
output_size
=
s
->
blocksize
*
s
->
channels
*
(
s
->
is32
?
4
:
2
);
output_size
=
s
->
blocksize
*
s
->
channels
*
av_get_bytes_per_sample
(
avctx
->
sample_fmt
);
if
(
output_size
>
alloc_data_size
)
{
av_log
(
s
->
avctx
,
AV_LOG_ERROR
,
"output data size is larger than "
"allocated data size
\n
"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment