Mercurial > cgi-bin > hgwebdir.cgi > PR > Applications > VSs > VSs__H264__App
diff libavutil/error.h @ 2:897f711a7157
rearrange to work with autoconf
| author | Nina Engelhardt <nengel@mailbox.tu-berlin.de> |
|---|---|
| date | Tue, 25 Sep 2012 15:55:33 +0200 |
| parents | |
| children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/libavutil/error.h Tue Sep 25 15:55:33 2012 +0200 1.3 @@ -0,0 +1,53 @@ 1.4 +/* 1.5 + * This file is part of FFmpeg. 1.6 + * 1.7 + * FFmpeg is free software; you can redistribute it and/or 1.8 + * modify it under the terms of the GNU Lesser General Public 1.9 + * License as published by the Free Software Foundation; either 1.10 + * version 2.1 of the License, or (at your option) any later version. 1.11 + * 1.12 + * FFmpeg is distributed in the hope that it will be useful, 1.13 + * but WITHOUT ANY WARRANTY; without even the implied warranty of 1.14 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 1.15 + * Lesser General Public License for more details. 1.16 + * 1.17 + * You should have received a copy of the GNU Lesser General Public 1.18 + * License along with FFmpeg; if not, write to the Free Software 1.19 + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 1.20 + */ 1.21 + 1.22 +/** 1.23 + * @file 1.24 + * error code definitions 1.25 + */ 1.26 + 1.27 +#ifndef AVUTIL_ERROR_H 1.28 +#define AVUTIL_ERROR_H 1.29 + 1.30 +#include <errno.h> 1.31 +#include "common.h" 1.32 + 1.33 +/* error handling */ 1.34 +#if EDOM > 0 1.35 +#define AVERROR(e) (-(e)) ///< Returns a negative error code from a POSIX error code, to return from library functions. 1.36 +#define AVUNERROR(e) (-(e)) ///< Returns a POSIX error code from a library function error return value. 1.37 +#else 1.38 +/* Some platforms have E* and errno already negated. */ 1.39 +#define AVERROR(e) (e) 1.40 +#define AVUNERROR(e) (e) 1.41 +#endif 1.42 + 1.43 +#define AVERROR_EOF AVERROR(EPIPE) ///< End of file 1.44 + 1.45 + 1.46 +/** 1.47 + * Puts a description of the AVERROR code errnum in errbuf. 1.48 + * In case of failure the global variable errno is set to indicate the 1.49 + * error. 1.50 + * 1.51 + * @param errbuf_size the size in bytes of errbuf 1.52 + * @return 0 on success, a negative value otherwise 1.53 + */ 1.54 +int av_strerror(int errnum, char *errbuf, size_t errbuf_size); 1.55 + 1.56 +#endif /* AVUTIL_ERROR_H */
