[FFmpeg-devel] [FFmpeg-cvslog] avcodec/libdav1d: fix build after a recent API break

James Almer jamrial at gmail.com
Wed Nov 14 17:42:29 EET 2018


On 11/14/2018 12:38 PM, Nicolas George wrote:
> James Almer (2018-11-14):
>> -    res = dav1d_decode(dav1d->c, data, &p);
>> +    res = dav1d_send_data(dav1d->c, data);
>> +    if (res < 0) {
>> +        if (res == -EINVAL)
>> +            res = AVERROR_INVALIDDATA;
>> +        if (res != -EAGAIN)
>> +            return res;
>> +    }
>> +
>> +    res = dav1d_get_picture(dav1d->c, &p);
> 
> I just noticed this: the lack of AVERROR() looks very suspicious. It
> seems this library uses directly -errno values, which will coincide with
> AVERROR() on most systems but not all.
> 
> Regards,

I considered that, but I don't think libdav1d is supported on systems
where errno values are already negated, as every single one of their
internal error checks would fail. So it's probably safe to do this.


More information about the ffmpeg-devel mailing list