[FFmpeg-cvslog] avformat/udp: modify the not write-only to read-only mode.
Xuchen Su
git at videolan.org
Mon Jan 20 08:29:24 EET 2020
ffmpeg | branch: master | Xuchen Su <xuchen.su at qq.com> | Tue Nov 26 15:02:06 2019 +0800| [9faee5bc148fdf4d5340cdcf7e464078972dc72c] | committer: Steven Liu
avformat/udp: modify the not write-only to read-only mode.
not write-only include read-write pseudo flag. so make the flag read-only
Signed-off-by: Steven Liu <lq at chinaffmpeg.org>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9faee5bc148fdf4d5340cdcf7e464078972dc72c
---
libavformat/udp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavformat/udp.c b/libavformat/udp.c
index f4ec148a2f..1ab576e80e 100644
--- a/libavformat/udp.c
+++ b/libavformat/udp.c
@@ -797,7 +797,7 @@ static int udp_open(URLContext *h, const char *uri, int flags)
* receiving UDP packets from other sources aimed at the same UDP
* port. This fails on windows. This makes sending to the same address
* using sendto() fail, so only do it if we're opened in read-only mode. */
- if (s->is_multicast && !(h->flags & AVIO_FLAG_WRITE)) {
+ if (s->is_multicast && (h->flags & AVIO_FLAG_READ)) {
bind_ret = bind(udp_fd,(struct sockaddr *)&s->dest_addr, len);
}
/* bind to the local address if not multicast or if the multicast
More information about the ffmpeg-cvslog
mailing list