diff mbox series

[FFmpeg-devel,v2,3/3] avformat/prompeg: av_dict_set() -> av_dict_set_int()

Message ID 1590577847-24670-3-git-send-email-lance.lmwang@gmail.com
State Accepted
Headers show
Series [FFmpeg-devel,v2,1/3] avformat/rtspdec: av_dict_set() -> av_dict_set_int() | expand

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

Lance Wang May 27, 2020, 11:10 a.m. UTC
From: Limin Wang <lance.lmwang@gmail.com>

Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
---
 libavformat/prompeg.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/libavformat/prompeg.c b/libavformat/prompeg.c
index 9770a91..7b2e5e8 100644
--- a/libavformat/prompeg.c
+++ b/libavformat/prompeg.c
@@ -291,8 +291,7 @@  static int prompeg_open(URLContext *h, const char *uri, int flags) {
     }
 
     if (s->ttl > 0) {
-        snprintf(buf, sizeof (buf), "%d", s->ttl);
-        av_dict_set(&udp_opts, "ttl", buf, 0);
+        av_dict_set_int(&udp_opts, "ttl", s->ttl, 0);
     }
 
     ff_url_join(buf, sizeof (buf), "udp", NULL, hostname, rtp_port + 2, NULL);