On Sat, 25 Feb 2012 00:05:41 -0500, Justin Ruggles <[email protected]> wrote: > Useful to return instead of -1 when the cause of the error is unknown, > typically from an external library. > --- > doc/APIchanges | 3 +++ > libavutil/avutil.h | 4 ++-- > libavutil/error.h | 1 + > 3 files changed, 6 insertions(+), 2 deletions(-) > > diff --git a/doc/APIchanges b/doc/APIchanges > index 78e2bfc..0cdb3be 100644 > --- a/doc/APIchanges > +++ b/doc/APIchanges > @@ -12,6 +12,9 @@ libavutil: 2011-04-18 > > API changes, most recent first: > > +2012-xx-xx - xxxxxxx - lavu 51.24.0 - error.h > + Add AVERROR_UNKNOWN > + > 2012-xx-xx - xxxxxxx - lavc 54.x.x > Add duration field to AVCodecParserContext > > diff --git a/libavutil/avutil.h b/libavutil/avutil.h > index 8d474e4..c9c7141 100644 > --- a/libavutil/avutil.h > +++ b/libavutil/avutil.h > @@ -153,8 +153,8 @@ > */ > > #define LIBAVUTIL_VERSION_MAJOR 51 > -#define LIBAVUTIL_VERSION_MINOR 23 > -#define LIBAVUTIL_VERSION_MICRO 1 > +#define LIBAVUTIL_VERSION_MINOR 24 > +#define LIBAVUTIL_VERSION_MICRO 0 > > #define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \ > LIBAVUTIL_VERSION_MINOR, \ > diff --git a/libavutil/error.h b/libavutil/error.h > index 2db65cb..11bcc5c 100644 > --- a/libavutil/error.h > +++ b/libavutil/error.h > @@ -58,6 +58,7 @@ > #define AVERROR_PROTOCOL_NOT_FOUND (-MKTAG(0xF8,'P','R','O')) ///< Protocol > not found > #define AVERROR_STREAM_NOT_FOUND (-MKTAG(0xF8,'S','T','R')) ///< Stream > not found > #define AVERROR_BUG (-MKTAG( 'B','U','G',' ')) ///< Bug > detected, please report the issue > +#define AVERROR_UNKNOWN (-MKTAG( 'U','N','K','N')) ///< Unknown > error, typically from an external library > > /** > * Put a description of the AVERROR code errnum in errbuf. > -- > 1.7.1 >
You should also add an entry to the table in av_strerror(). -- Anton Khirnov _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
