Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
F
ffmpeg
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
ffmpeg
Commits
5c37ffca
Commit
5c37ffca
authored
Jan 01, 2015
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avformat/flvdec: add several error messages to error conditions
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
d25d9296
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
+10
-2
flvdec.c
libavformat/flvdec.c
+10
-2
No files found.
libavformat/flvdec.c
View file @
5c37ffca
...
...
@@ -405,8 +405,10 @@ static int amf_parse_object(AVFormatContext *s, AVStream *astream,
num_val
=
avio_r8
(
ioc
);
break
;
case
AMF_DATA_TYPE_STRING
:
if
(
amf_get_string
(
ioc
,
str_val
,
sizeof
(
str_val
))
<
0
)
if
(
amf_get_string
(
ioc
,
str_val
,
sizeof
(
str_val
))
<
0
)
{
av_log
(
s
,
AV_LOG_ERROR
,
"AMF_DATA_TYPE_STRING parsing failed
\n
"
);
return
-
1
;
}
break
;
case
AMF_DATA_TYPE_OBJECT
:
if
((
vstream
||
astream
)
&&
key
&&
...
...
@@ -421,8 +423,10 @@ static int amf_parse_object(AVFormatContext *s, AVStream *astream,
if
(
amf_parse_object
(
s
,
astream
,
vstream
,
str_val
,
max_pos
,
depth
+
1
)
<
0
)
return
-
1
;
// if we couldn't skip, bomb out.
if
(
avio_r8
(
ioc
)
!=
AMF_END_OF_OBJECT
)
if
(
avio_r8
(
ioc
)
!=
AMF_END_OF_OBJECT
)
{
av_log
(
s
,
AV_LOG_ERROR
,
"Missing AMF_END_OF_OBJECT in AMF_DATA_TYPE_OBJECT
\n
"
);
return
-
1
;
}
break
;
case
AMF_DATA_TYPE_NULL
:
case
AMF_DATA_TYPE_UNDEFINED
:
...
...
@@ -438,7 +442,10 @@ static int amf_parse_object(AVFormatContext *s, AVStream *astream,
depth
+
1
)
<
0
)
return
-
1
;
if
(
avio_r8
(
ioc
)
!=
AMF_END_OF_OBJECT
)
if
(
avio_r8
(
ioc
)
!=
AMF_END_OF_OBJECT
)
{
av_log
(
s
,
AV_LOG_ERROR
,
"Missing AMF_END_OF_OBJECT in AMF_DATA_TYPE_MIXEDARRAY
\n
"
);
return
-
1
;
}
break
;
case
AMF_DATA_TYPE_ARRAY
:
{
...
...
@@ -455,6 +462,7 @@ static int amf_parse_object(AVFormatContext *s, AVStream *astream,
avio_skip
(
ioc
,
8
+
2
);
// timestamp (double) and UTC offset (int16)
break
;
default:
// unsupported type, we couldn't skip
av_log
(
s
,
AV_LOG_ERROR
,
"unsupported amf type %d
\n
"
,
amf_type
);
return
-
1
;
}
...
...
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