From f87b1b373a0df55080c1e6a5874f9a0a75c6fee8 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Mon, 4 Apr 2011 20:11:19 +0200 Subject: avio: AVIO_ prefixes for URL_ open flags. --- libavformat/avio.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'libavformat/avio.c') diff --git a/libavformat/avio.c b/libavformat/avio.c index 976499ff14..8c53e5cd36 100644 --- a/libavformat/avio.c +++ b/libavformat/avio.c @@ -144,7 +144,7 @@ int ffurl_connect(URLContext* uc) return err; uc->is_connected = 1; //We must be careful here as ffurl_seek() could be slow, for example for http - if( (uc->flags & (URL_WRONLY | URL_RDWR)) + if( (uc->flags & (AVIO_WRONLY | AVIO_RDWR)) || !strcmp(uc->prot->name, "file")) if(!uc->is_streamed && ffurl_seek(uc, 0, SEEK_SET) < 0) uc->is_streamed= 1; @@ -275,7 +275,7 @@ static inline int retry_transfer_wrapper(URLContext *h, unsigned char *buf, int ret = transfer_func(h, buf+len, size-len); if (ret == AVERROR(EINTR)) continue; - if (h->flags & URL_FLAG_NONBLOCK) + if (h->flags & AVIO_FLAG_NONBLOCK) return ret; if (ret == AVERROR(EAGAIN)) { ret = 0; @@ -296,21 +296,21 @@ static inline int retry_transfer_wrapper(URLContext *h, unsigned char *buf, int int ffurl_read(URLContext *h, unsigned char *buf, int size) { - if (h->flags & URL_WRONLY) + if (h->flags & AVIO_WRONLY) return AVERROR(EIO); return retry_transfer_wrapper(h, buf, size, 1, h->prot->url_read); } int ffurl_read_complete(URLContext *h, unsigned char *buf, int size) { - if (h->flags & URL_WRONLY) + if (h->flags & AVIO_WRONLY) return AVERROR(EIO); return retry_transfer_wrapper(h, buf, size, size, h->prot->url_read); } int ffurl_write(URLContext *h, const unsigned char *buf, int size) { - if (!(h->flags & (URL_WRONLY | URL_RDWR))) + if (!(h->flags & (AVIO_WRONLY | AVIO_RDWR))) return AVERROR(EIO); /* avoid sending too big packets */ if (h->max_packet_size && size > h->max_packet_size) @@ -348,7 +348,7 @@ int ffurl_close(URLContext *h) int url_exist(const char *filename) { URLContext *h; - if (ffurl_open(&h, filename, URL_RDONLY) < 0) + if (ffurl_open(&h, filename, AVIO_RDONLY) < 0) return 0; ffurl_close(h); return 1; -- cgit v1.2.3