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
62340581
Commit
62340581
authored
Aug 03, 2014
by
Diego Biurrun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
huffyuv: Return proper error codes
parent
3160bdc7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
huffyuvdec.c
libavcodec/huffyuvdec.c
+3
-3
No files found.
libavcodec/huffyuvdec.c
View file @
62340581
...
...
@@ -98,7 +98,7 @@ static int read_len_table(uint8_t *dst, GetBitContext *gb)
repeat
=
get_bits
(
gb
,
8
);
if
(
i
+
repeat
>
256
||
get_bits_left
(
gb
)
<
0
)
{
av_log
(
NULL
,
AV_LOG_ERROR
,
"Error reading huffman table
\n
"
);
return
-
1
;
return
AVERROR_INVALIDDATA
;
}
while
(
repeat
--
)
dst
[
i
++
]
=
val
;
...
...
@@ -261,7 +261,7 @@ static av_cold int decode_init(AVCodecContext *avctx)
int
method
,
interlace
;
if
(
avctx
->
extradata_size
<
4
)
return
-
1
;
return
AVERROR_INVALIDDATA
;
method
=
avctx
->
extradata
[
0
];
s
->
decorrelate
=
method
&
64
?
1
:
0
;
...
...
@@ -508,7 +508,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *got_frame,
}
if
((
unsigned
)
(
buf_size
-
table_size
)
>=
INT_MAX
/
8
)
return
-
1
;
return
AVERROR_INVALIDDATA
;
init_get_bits
(
&
s
->
gb
,
s
->
bitstream_buffer
+
table_size
,
(
buf_size
-
table_size
)
*
8
);
...
...
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