Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Xiph.Org
ffmpeg2theora
Commits
c7ac4419
Commit
c7ac4419
authored
Aug 19, 2009
by
Jan Gerber
Browse files
output valid json for errors, depend on 1.1.0 to work with current theora trunk
parent
d0ebd89c
Changes
2
Hide whitespace changes
Inline
Side-by-side
SConstruct
View file @
c7ac4419
...
...
@@ -107,7 +107,7 @@ if not conf.CheckPKGConfig(pkgconfig_version):
print
'pkg-config >= %s not found.'
%
pkgconfig_version
Exit
(
1
)
XIPH_LIBS
=
"ogg >= 1.1 vorbis vorbisenc theoradec >= 1.1
beta1
theoraenc >= 1.1
beta1
"
XIPH_LIBS
=
"ogg >= 1.1 vorbis vorbisenc theoradec >= 1.1
.0
theoraenc >= 1.1
.0
"
if
not
conf
.
CheckPKG
(
XIPH_LIBS
):
print
'some xiph libs are missing, ffmpeg2theora depends on %s'
%
XIPH_LIBS
...
...
src/ffmpeg2theora.c
View file @
c7ac4419
...
...
@@ -2537,7 +2537,7 @@ int main(int argc, char **argv) {
(
double
)
convert
->
context
->
start_time
/
AV_TIME_BASE
;
if
(
info
.
twopass
!=
1
&&
!
info
.
outfile
)
{
if
(
info
.
frontend
)
fprintf
(
info
.
frontend
,
"
\"
{result
\"
:
\"
Unable to open output file.
\"
}
\n
"
);
fprintf
(
info
.
frontend
,
"
{
\"
code
\"
:
\"
badfile
\"
,
\"
error
\"
:
\"
Unable to open output file.
\"
}
\n
"
);
else
fprintf
(
stderr
,
"
\n
Unable to open output file `%s'.
\n
"
,
outputfile_name
);
return
(
1
);
...
...
@@ -2552,9 +2552,9 @@ int main(int argc, char **argv) {
}
else
{
if
(
info
.
frontend
)
fprintf
(
info
.
frontend
,
"{
\"
code
\"
:
\"
badfile
\"
,
\"
input format not supported.
\"
}
\n
"
);
fprintf
(
info
.
frontend
,
"{
\"
code
\"
:
\"
badfile
\"
,
\"
error
\"
:
\"
input format not supported.
\"
}
\n
"
);
else
if
(
output_json
)
fprintf
(
stdout
,
"{
\"
code
\"
:
\"
badfile
\"
,
\"
input format not supported.
\"
}
\n
"
);
fprintf
(
stdout
,
"{
\"
code
\"
:
\"
badfile
\"
,
\"
error
\"
:
\"
input format not supported.
\"
}
\n
"
);
else
fprintf
(
stderr
,
"
\n
Unable to decode input.
\n
"
);
return
(
1
);
...
...
@@ -2563,9 +2563,9 @@ int main(int argc, char **argv) {
}
else
{
if
(
info
.
frontend
)
fprintf
(
info
.
frontend
,
"{
\"
code
\"
:
\"
badfile
\"
,
\"
file does not exist or has unknown data format.
\"
}
\n
"
);
fprintf
(
info
.
frontend
,
"{
\"
code
\"
:
\"
badfile
\"
,
\"
error
\"
:
\"
file does not exist or has unknown data format.
\"
}
\n
"
);
else
if
(
output_json
)
fprintf
(
stdout
,
"{
\"
code
\"
:
\"
badfile
\"
,
\"
file does not exist or has unknown data format.
\"
}
\n
"
);
fprintf
(
stdout
,
"{
\"
code
\"
:
\"
badfile
\"
,
\"
error
\"
:
\"
file does not exist or has unknown data format.
\"
}
\n
"
);
else
fprintf
(
stderr
,
"
\n
File `%s' does not exist or has an unknown data format.
\n
"
,
inputfile_name
);
return
(
1
);
...
...
Write
Preview
Supports
Markdown
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