Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
22267492
Commit
22267492
authored
Aug 06, 2006
by
Jean-Paul Saman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sanity checking
parent
416c0651
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
modules/codec/ffmpeg/ffmpeg.c
modules/codec/ffmpeg/ffmpeg.c
+7
-4
No files found.
modules/codec/ffmpeg/ffmpeg.c
View file @
22267492
...
...
@@ -222,8 +222,8 @@ static int OpenDecoder( vlc_object_t *p_this )
int
i_cat
,
i_codec_id
,
i_result
;
char
*
psz_namecodec
;
AVCodecContext
*
p_context
;
AVCodec
*
p_codec
;
AVCodecContext
*
p_context
=
NULL
;
AVCodec
*
p_codec
=
NULL
;
/* *** determine codec type *** */
if
(
!
E_
(
GetFfmpegCodec
)(
p_dec
->
fmt_in
.
i_codec
,
&
i_cat
,
&
i_codec_id
,
...
...
@@ -244,7 +244,8 @@ static int OpenDecoder( vlc_object_t *p_this )
E_
(
InitLibavcodec
)(
p_this
);
/* *** ask ffmpeg for a decoder *** */
if
(
!
(
p_codec
=
avcodec_find_decoder
(
i_codec_id
)
)
)
p_codec
=
avcodec_find_decoder
(
i_codec_id
);
if
(
!
p_codec
)
{
msg_Dbg
(
p_dec
,
"codec not found (%s)"
,
psz_namecodec
);
return
VLC_EGENERIC
;
...
...
@@ -252,6 +253,8 @@ static int OpenDecoder( vlc_object_t *p_this )
/* *** get a p_context *** */
p_context
=
avcodec_alloc_context
();
if
(
!
p_context
)
return
-
ENOMEM
;
p_context
->
debug
=
config_GetInt
(
p_dec
,
"ffmpeg-debug"
);
p_context
->
opaque
=
(
void
*
)
p_this
;
...
...
@@ -325,7 +328,7 @@ static void CloseDecoder( vlc_object_t *p_this )
{
if
(
p_sys
->
p_context
->
extradata
)
free
(
p_sys
->
p_context
->
extradata
);
p_sys
->
p_context
->
extradata
=
NULL
;
vlc_mutex_lock
(
lockval
.
p_address
);
avcodec_close
(
p_sys
->
p_context
);
vlc_mutex_unlock
(
lockval
.
p_address
);
...
...
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