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
2375a85c
Commit
2375a85c
authored
Jul 01, 2015
by
Rodger Combs
Committed by
Michael Niedermayer
Jul 06, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ffmpeg_opt: allow the user to ignore unused stream maps
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
8234f0e3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
+10
-2
ffmpeg_opt.c
ffmpeg_opt.c
+10
-2
No files found.
ffmpeg_opt.c
View file @
2375a85c
...
...
@@ -231,6 +231,7 @@ static int opt_map(void *optctx, const char *opt, const char *arg)
int
sync_file_idx
=
-
1
,
sync_stream_idx
=
0
;
char
*
p
,
*
sync
;
char
*
map
;
char
*
allow_unused
;
if
(
*
arg
==
'-'
)
{
negative
=
1
;
...
...
@@ -275,6 +276,8 @@ static int opt_map(void *optctx, const char *opt, const char *arg)
exit_program
(
1
);
}
}
else
{
if
(
allow_unused
=
strchr
(
map
,
'?'
))
*
allow_unused
=
0
;
file_idx
=
strtol
(
map
,
&
p
,
0
);
if
(
file_idx
>=
nb_input_files
||
file_idx
<
0
)
{
av_log
(
NULL
,
AV_LOG_FATAL
,
"Invalid input file index: %d.
\n
"
,
file_idx
);
...
...
@@ -312,8 +315,13 @@ static int opt_map(void *optctx, const char *opt, const char *arg)
}
if
(
!
m
)
{
av_log
(
NULL
,
AV_LOG_FATAL
,
"Stream map '%s' matches no streams.
\n
"
,
arg
);
exit_program
(
1
);
if
(
allow_unused
)
{
av_log
(
NULL
,
AV_LOG_VERBOSE
,
"Stream map '%s' matches no streams; ignoring.
\n
"
,
arg
);
}
else
{
av_log
(
NULL
,
AV_LOG_FATAL
,
"Stream map '%s' matches no streams.
\n
"
"To ignore this, add a trailing '?' to the map.
\n
"
,
arg
);
exit_program
(
1
);
}
}
av_freep
(
&
map
);
...
...
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