[FFmpeg-cvslog] udp: Fix sign of error codes.
Michael Niedermayer
git at videolan.org
Thu Feb 23 23:34:19 CET 2012
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Thu Feb 23 23:22:16 2012 +0100| [29a8f6b8d4eb531b43f0139261c2b7b5ef7fb443] | committer: Michael Niedermayer
udp: Fix sign of error codes.
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=29a8f6b8d4eb531b43f0139261c2b7b5ef7fb443
---
libavformat/udp.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/libavformat/udp.c b/libavformat/udp.c
index 9694ad2..309b18c 100644
--- a/libavformat/udp.c
+++ b/libavformat/udp.c
@@ -335,7 +335,7 @@ static void *circular_buffer_task( void *_URLContext)
int len;
if (ff_check_interrupt(&h->interrupt_callback)) {
- s->circular_buffer_error = EINTR;
+ s->circular_buffer_error = AVERROR(EINTR);
goto end;
}
@@ -347,7 +347,7 @@ static void *circular_buffer_task( void *_URLContext)
if (ret < 0) {
if (ff_neterrno() == AVERROR(EINTR))
continue;
- s->circular_buffer_error = EIO;
+ s->circular_buffer_error = AVERROR(EIO);
goto end;
}
@@ -361,14 +361,14 @@ static void *circular_buffer_task( void *_URLContext)
/* No Space left, error, what do we do now */
if(left < UDP_MAX_PKT_SIZE + 4) {
av_log(h, AV_LOG_ERROR, "circular_buffer: OVERRUN\n");
- s->circular_buffer_error = EIO;
+ s->circular_buffer_error = AVERROR(EIO);
goto end;
}
left = FFMIN(left, s->fifo->end - s->fifo->wptr);
len = recv(s->udp_fd, s->tmp+4, sizeof(s->tmp)-4, 0);
if (len < 0) {
if (ff_neterrno() != AVERROR(EAGAIN) && ff_neterrno() != AVERROR(EINTR)) {
- s->circular_buffer_error = EIO;
+ s->circular_buffer_error = AVERROR(EIO);
goto end;
}
continue;
More information about the ffmpeg-cvslog
mailing list