Commit de1f0bcf authored by Michael Smith's avatar Michael Smith

Stupid bug setting wrong unset value for min/max bitrates

svn path=/trunk/vorbis-tools/; revision=2406
parent e8015967
...@@ -62,8 +62,10 @@ int oe_encode(oe_enc_opt *opt) ...@@ -62,8 +62,10 @@ int oe_encode(oe_enc_opt *opt)
} }
else else
{ {
if(vorbis_encode_init(&vi, opt->channels, opt->rate, opt->min_bitrate*1000, if(vorbis_encode_init(&vi, opt->channels, opt->rate,
opt->bitrate*1000, opt->max_bitrate*1000)) opt->min_bitrate>0?opt->min_bitrate*1000:-1,
opt->bitrate*1000,
opt->max_bitrate>0?opt->max_bitrate*1000:-1))
{ {
fprintf(stderr, "Mode initialisation failed: invalid parameters for bitrate\n"); fprintf(stderr, "Mode initialisation failed: invalid parameters for bitrate\n");
vorbis_info_clear(&vi); vorbis_info_clear(&vi);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment