aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorTimo Rothenpieler <timo@rothenpieler.org>2025-06-26 02:37:15 +0200
committerTimo Rothenpieler <timo@rothenpieler.org>2025-07-03 22:18:10 +0200
commit23c70e3740b29c42db54f583fefaa2cae4fc360f (patch)
treedb5a2fdf8379d9bba0da624f23b4811e6833662d /libavformat
parent492aef2d94e16685e13466a653019dc8ca3293a9 (diff)
downloadffmpeg-23c70e3740b29c42db54f583fefaa2cae4fc360f.tar.gz
avformat/udp: don't override 0 localport
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/udp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/udp.c b/libavformat/udp.c
index c1ebdd1222..30f075de8e 100644
--- a/libavformat/udp.c
+++ b/libavformat/udp.c
@@ -780,7 +780,7 @@ static int udp_open(URLContext *h, const char *uri, int flags)
goto fail;
}
- if ((s->is_multicast || s->local_port <= 0) && (h->flags & AVIO_FLAG_READ))
+ if ((s->is_multicast || s->local_port < 0) && (h->flags & AVIO_FLAG_READ))
s->local_port = port;
udp_fd = udp_socket_create(h, &my_addr, &len, s->localaddr);