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
ca1a2a47
Commit
ca1a2a47
authored
Mar 15, 2011
by
Stefano Sabatini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavf: make compute_pkt_fields2() return meaningful error values
parent
0c55c6d3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
utils.c
libavformat/utils.c
+3
-3
No files found.
libavformat/utils.c
View file @
ca1a2a47
...
@@ -2931,7 +2931,7 @@ static int compute_pkt_fields2(AVFormatContext *s, AVStream *st, AVPacket *pkt){
...
@@ -2931,7 +2931,7 @@ static int compute_pkt_fields2(AVFormatContext *s, AVStream *st, AVPacket *pkt){
pkt
->
pts
,
pkt
->
dts
,
st
->
cur_dts
,
delay
,
pkt
->
size
,
pkt
->
stream_index
);
pkt
->
pts
,
pkt
->
dts
,
st
->
cur_dts
,
delay
,
pkt
->
size
,
pkt
->
stream_index
);
/* if(pkt->pts == AV_NOPTS_VALUE && pkt->dts == AV_NOPTS_VALUE)
/* if(pkt->pts == AV_NOPTS_VALUE && pkt->dts == AV_NOPTS_VALUE)
return
-1
;*/
return
AVERROR(EINVAL)
;*/
/* duration field */
/* duration field */
if
(
pkt
->
duration
==
0
)
{
if
(
pkt
->
duration
==
0
)
{
...
@@ -2966,11 +2966,11 @@ static int compute_pkt_fields2(AVFormatContext *s, AVStream *st, AVPacket *pkt){
...
@@ -2966,11 +2966,11 @@ static int compute_pkt_fields2(AVFormatContext *s, AVStream *st, AVPacket *pkt){
av_log
(
s
,
AV_LOG_ERROR
,
av_log
(
s
,
AV_LOG_ERROR
,
"Application provided invalid, non monotonically increasing dts to muxer in stream %d: %"
PRId64
" >= %"
PRId64
"
\n
"
,
"Application provided invalid, non monotonically increasing dts to muxer in stream %d: %"
PRId64
" >= %"
PRId64
"
\n
"
,
st
->
index
,
st
->
cur_dts
,
pkt
->
dts
);
st
->
index
,
st
->
cur_dts
,
pkt
->
dts
);
return
-
1
;
return
AVERROR
(
EINVAL
)
;
}
}
if
(
pkt
->
dts
!=
AV_NOPTS_VALUE
&&
pkt
->
pts
!=
AV_NOPTS_VALUE
&&
pkt
->
pts
<
pkt
->
dts
){
if
(
pkt
->
dts
!=
AV_NOPTS_VALUE
&&
pkt
->
pts
!=
AV_NOPTS_VALUE
&&
pkt
->
pts
<
pkt
->
dts
){
av_log
(
s
,
AV_LOG_ERROR
,
"pts < dts in stream %d
\n
"
,
st
->
index
);
av_log
(
s
,
AV_LOG_ERROR
,
"pts < dts in stream %d
\n
"
,
st
->
index
);
return
-
1
;
return
AVERROR
(
EINVAL
)
;
}
}
// av_log(s, AV_LOG_DEBUG, "av_write_frame: pts2:%"PRId64" dts2:%"PRId64"\n", pkt->pts, pkt->dts);
// av_log(s, AV_LOG_DEBUG, "av_write_frame: pts2:%"PRId64" dts2:%"PRId64"\n", pkt->pts, pkt->dts);
...
...
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