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
1bc9e4c5
Commit
1bc9e4c5
authored
Jul 03, 2012
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
jvdec: remove buf_size
It is same as avpkt->size. Signed-off-by:
Paul B Mahol
<
onemda@gmail.com
>
parent
1c638cfc
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
4 deletions
+3
-4
jvdec.c
libavcodec/jvdec.c
+3
-4
No files found.
libavcodec/jvdec.c
View file @
1bc9e4c5
...
...
@@ -133,9 +133,8 @@ static int decode_frame(AVCodecContext *avctx,
AVPacket
*
avpkt
)
{
JvContext
*
s
=
avctx
->
priv_data
;
int
buf_size
=
avpkt
->
size
;
const
uint8_t
*
buf
=
avpkt
->
data
;
const
uint8_t
*
buf_end
=
buf
+
buf_
size
;
const
uint8_t
*
buf_end
=
buf
+
avpkt
->
size
;
int
video_size
,
video_type
,
i
,
j
;
video_size
=
AV_RL32
(
buf
);
...
...
@@ -143,7 +142,7 @@ static int decode_frame(AVCodecContext *avctx,
buf
+=
5
;
if
(
video_size
)
{
if
(
video_size
<
0
||
video_size
>
buf_
size
)
{
if
(
video_size
<
0
||
video_size
>
avpkt
->
size
)
{
av_log
(
avctx
,
AV_LOG_ERROR
,
"video size %d invalid
\n
"
,
video_size
);
return
AVERROR_INVALIDDATA
;
}
...
...
@@ -194,7 +193,7 @@ static int decode_frame(AVCodecContext *avctx,
*
(
AVFrame
*
)
data
=
s
->
frame
;
}
return
buf_
size
;
return
avpkt
->
size
;
}
static
av_cold
int
decode_close
(
AVCodecContext
*
avctx
)
...
...
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