char path[1024];
const char *p;
int i, max_retry_count = 3;
+ int rtcpflags;
av_url_split(NULL, 0, NULL, 0, hostname, sizeof(hostname), &rtp_port,
path, sizeof(path), uri);
s->local_rtpport = -1;
continue;
}
+ rtcpflags = flags | AVIO_FLAG_WRITE;
if (s->local_rtcpport < 0) {
s->local_rtcpport = s->local_rtpport + 1;
build_udp_url(s, buf, sizeof(buf),
hostname, s->rtcp_port, s->local_rtcpport,
sources, block);
- if (ffurl_open_whitelist(&s->rtcp_hd, buf, flags,
+ if (ffurl_open_whitelist(&s->rtcp_hd, buf, rtcpflags,
&h->interrupt_callback, NULL,
h->protocol_whitelist, h->protocol_blacklist) < 0) {
s->local_rtpport = s->local_rtcpport = -1;
build_udp_url(s, buf, sizeof(buf),
hostname, s->rtcp_port, s->local_rtcpport,
sources, block);
- if (ffurl_open_whitelist(&s->rtcp_hd, buf, flags, &h->interrupt_callback,
+ if (ffurl_open_whitelist(&s->rtcp_hd, buf, rtcpflags, &h->interrupt_callback,
NULL, h->protocol_whitelist, h->protocol_blacklist) < 0)
goto fail;
break;
append_source_addrs(url, sizeof(url), "block",
rtsp_st->nb_exclude_source_addrs,
rtsp_st->exclude_source_addrs);
- err = ffurl_open_whitelist(&rtsp_st->rtp_handle, url, AVIO_FLAG_READ_WRITE,
+ err = ffurl_open_whitelist(&rtsp_st->rtp_handle, url, AVIO_FLAG_READ,
&s->interrupt_callback, &opts, s->protocol_whitelist, s->protocol_blacklist);
av_dict_free(&opts);