Mercurial > libavutil.hg
comparison error.h @ 886:d4062b438548 libavutil
error.h: test EDOM instead of EINVAL
C99 doesn't require EINVAL, only EDOM, EILSEQ, and ERANGE.
author | mru |
---|---|
date | Sun, 14 Mar 2010 22:25:35 +0000 |
parents | 311037a6cb91 |
children | 25135d2dca10 |
comparison
equal
deleted
inserted
replaced
885:311037a6cb91 | 886:d4062b438548 |
---|---|
26 | 26 |
27 #include <errno.h> | 27 #include <errno.h> |
28 #include "avutil.h" | 28 #include "avutil.h" |
29 | 29 |
30 /* error handling */ | 30 /* error handling */ |
31 #if EINVAL > 0 | 31 #if EDOM > 0 |
32 #define AVERROR(e) (-(e)) /**< Returns a negative error code from a POSIX error code, to return from library functions. */ | 32 #define AVERROR(e) (-(e)) /**< Returns a negative error code from a POSIX error code, to return from library functions. */ |
33 #define AVUNERROR(e) (-(e)) /**< Returns a POSIX error code from a library function error return value. */ | 33 #define AVUNERROR(e) (-(e)) /**< Returns a POSIX error code from a library function error return value. */ |
34 #else | 34 #else |
35 /* Some platforms have E* and errno already negated. */ | 35 /* Some platforms have E* and errno already negated. */ |
36 #define AVERROR(e) (e) | 36 #define AVERROR(e) (e) |