From 8fa36ae09dddb1b639b4df5d505c0dbcf4e916e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Revol?= Date: Tue, 13 Feb 2007 18:26:14 +0000 Subject: This fixes error handling for BeOS, removing the need for some ifdefs. AVERROR_ defines are moved to avcodec.h as they are needed in there as well. Feel free to move that to avutil/common.h. Bumped up avcodec/format version numbers as though it's binary compatible we will want to rebuild apps as error values changed. Please from now on use return AVERROR(EFOO) instead of the ugly return -EFOO in your code. This also removes the need for berrno.h. Originally committed as revision 7965 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/dv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'libavcodec/dv.c') diff --git a/libavcodec/dv.c b/libavcodec/dv.c index 505c88d494..b5f15df27a 100644 --- a/libavcodec/dv.c +++ b/libavcodec/dv.c @@ -125,7 +125,7 @@ static int dvvideo_init(AVCodecContext *avctx) dv_vlc_map = av_mallocz_static(DV_VLC_MAP_LEV_SIZE*DV_VLC_MAP_RUN_SIZE*sizeof(struct dv_vlc_pair)); if (!dv_vlc_map) - return -ENOMEM; + return AVERROR(ENOMEM); /* dv_anchor lets each thread know its Id */ for (i=0; i