From 59d96941f0285a501989d5f2c9b69be0a1393ed5 Mon Sep 17 00:00:00 2001 From: Stefano Sabatini Date: Fri, 15 Apr 2011 16:42:09 +0200 Subject: avio: remove AVIO_* access symbols in favor of new AVIO_FLAG_* symbols Make AVIO_FLAG_ access constants work as flags, and in particular fix the behavior of functions (such as avio_check()) which expect them to be flags rather than modes. This breaks API. --- libavformat/rtmpproto.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'libavformat/rtmpproto.c') diff --git a/libavformat/rtmpproto.c b/libavformat/rtmpproto.c index 3413b62c8b..70e4b142d6 100644 --- a/libavformat/rtmpproto.c +++ b/libavformat/rtmpproto.c @@ -805,7 +805,7 @@ static int rtmp_open(URLContext *s, const char *uri, int flags) if (!rt) return AVERROR(ENOMEM); s->priv_data = rt; - rt->is_input = !(flags & AVIO_WRONLY); + rt->is_input = !(flags & AVIO_FLAG_WRITE); av_url_split(proto, sizeof(proto), NULL, 0, hostname, sizeof(hostname), &port, path, sizeof(path), s->filename); @@ -814,8 +814,8 @@ static int rtmp_open(URLContext *s, const char *uri, int flags) port = RTMP_DEFAULT_PORT; ff_url_join(buf, sizeof(buf), "tcp", NULL, hostname, port, NULL); - if (ffurl_open(&rt->stream, buf, AVIO_RDWR) < 0) { - av_log(s, AV_LOG_ERROR, "Cannot open connection %s\n", buf); + if (ffurl_open(&rt->stream, buf, AVIO_FLAG_READ_WRITE) < 0) { + av_log(s , AV_LOG_ERROR, "Cannot open connection %s\n", buf); goto fail; } -- cgit v1.2.3