[PATCH 3/7] Change the definition of AVERROR_INVALIDOPERATION at the next libavutil major bump, use a FFmpeg specific error code as ENOSYS has a different semantics.

Stefano Sabatini stefano.sabatini-lala
Fri Apr 2 15:21:09 CEST 2010


---
 libavutil/error.h |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/libavutil/error.h b/libavutil/error.h
index 590e5c6..d408cf8 100644
--- a/libavutil/error.h
+++ b/libavutil/error.h
@@ -39,22 +39,23 @@
 
 #if LIBAVUTIL_VERSION_MAJOR < 51
 #define AVERROR_INVALIDDATA AVERROR(EINVAL)  ///< Invalid data found when processing input
+#define AVERROR_INVALIDOPERATION AVERROR(ENOSYS)  ///< Invalid or illegal operation requested. The requested operation cannot be executed or implemented.
 #define AVERROR_IO          AVERROR(EIO)     ///< I/O error
 #define AVERROR_NOENT       AVERROR(ENOENT)  ///< No such file or directory
 #define AVERROR_NOFMT       AVERROR(EILSEQ)  ///< Unknown format
+#define AVERROR_NOTSUPP     AVERROR_INVALIDOPERATION ///< @deprecated Use AVERROR_INVALIDOPERATION instead.
 #define AVERROR_NOMEM       AVERROR(ENOMEM)  ///< Not enough memory
 #define AVERROR_NUMEXPECTED AVERROR(EDOM)    ///< Number syntax expected in filename
 #define AVERROR_UNKNOWN     AVERROR(EINVAL)  ///< Unknown error
 #endif
 
 #define AVERROR_EOF         AVERROR(EPIPE)   ///< End of file
-#define AVERROR_INVALIDOPERATION AVERROR(ENOSYS)  ///< Invalid or illegal operation requested. The requested operation cannot be executed or implemented.
-#define AVERROR_NOTSUPP     AVERROR_INVALIDOPERATION ///< @deprecated Use AVERROR_INVALIDOPERATION instead.
 
 #define AVERROR_PATCHWELCOME    (-MKTAG('P','A','W','E')) ///< Not yet implemented in FFmpeg, patches welcome
 
 #if LIBAVUTIL_VERSION_MAJOR > 50
 #define AVERROR_INVALIDDATA     (-MKTAG('I','N','D','A')) ///< Invalid data found when processing input
+#define AVERROR_INVALIDOPERATION ((-MKTAG('I','N','O','P')) ///< Invalid or illegal operation requested. The requested operation cannot be executed or implemented.
 #define AVERROR_NUMEXPECTED     (-MKTAG('N','U','E','X')) ///< Number syntax expected in filename
 #endif
 
-- 
1.7.0


--aM3YZ0Iwxop3KEKx--



More information about the ffmpeg-devel mailing list