Hi,

On Tue, May 24, 2011 at 1:35 AM, Anton Khirnov <[email protected]> wrote:
> ---
>  libavdevice/oss_audio.c |   24 ++++++++++++++++++++----
>  1 files changed, 20 insertions(+), 4 deletions(-)
[..]
> -    if (ap->sample_rate <= 0 || ap->channels <= 0)
> -        return -1;
> +    if (ap->sample_rate > 0)
> +        s->sample_rate = ap->sample_rate;
> +    if (ap->channels > 0)
> +        s->channels = ap->channels;
>
>     st = av_new_stream(s1, 0);
>     if (!st) {
>         return AVERROR(ENOMEM);
>     }
> -    s->sample_rate = ap->sample_rate;
> -    s->channels = ap->channels;

Doesn't this get rid of proper error reporting if a user set no
channels/samplerate using commandline parameters? Also, the private
options always override AVCodecContext options, right?

Ronald
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to