From d3298350bba0d5bdb43485356aa752528ec48d11 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Fri, 27 Nov 2009 13:48:37 +0000 Subject: [PATCH] Do not invent error codes but pass the error code on. Originally committed as revision 20630 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavdevice/oss_audio.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavdevice/oss_audio.c b/libavdevice/oss_audio.c index 8876bd2d24..f3edbdbef0 100644 --- a/libavdevice/oss_audio.c +++ b/libavdevice/oss_audio.c @@ -248,8 +248,8 @@ static int audio_read_packet(AVFormatContext *s1, AVPacket *pkt) int64_t cur_time; struct audio_buf_info abufi; - if (av_new_packet(pkt, s->frame_size) < 0) - return AVERROR(EIO); + if ((ret=av_new_packet(pkt, s->frame_size)) < 0) + return ret; ret = read(s->fd, pkt->data, pkt->size); if (ret <= 0){