[FFmpeg-devel] [PATCH 2/3] libx265: Return proper invalid data code

Clément Bœsch u at pkh.me
Tue Mar 3 16:55:26 CET 2015


On Tue, Mar 03, 2015 at 04:26:46PM +0100, Alexander Strasser wrote:
> On 2015-02-17 22:15 +0000, Derek Buitenhuis wrote:
> > On 2/17/2015 10:10 PM, James Almer wrote:
> > > Afaik, if the error is based on user input then EINVAL (Invalid argument) is correct.
> > > AVERROR_INVALIDDATA is when the error is in the bitstream/container and not an argument the 
> > > user passed to the library.
> > 
> > Right, I conflated the two.
> > 
> > Patch dropped.
> 
>   Sorry to reply to this old'ish thread. Just wanted to say I find the
> distinction kind of superficial; why do we do it again?
> 

Invalid data is related to reading an unknown source, it's not exactly
under user control.

Invalid argument is a user specified parameter. The user is often
responsible if this is triggered.

They are not really related.

-- 
Clément B.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 473 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150303/f3aecf39/attachment.asc>


More information about the ffmpeg-devel mailing list