From 4d6d70292e91a7ef027824d731b6b6570ceabf2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Storsj=C3=B6?= Date: Thu, 3 Oct 2013 09:09:56 +0200 Subject: [PATCH] rtmpproto: Pass the 'live' parameter in the right unit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The current magic numbers passed are values in seconds, while the parameter itself should be passed over the wire in milliseconds. This makes (some/all?) live streams from Red5 work correctly, that previously returned StreamNotFound even with "-rtmp_live live". After this commit, the default 'any' also works on these streams. Signed-off-by: Martin Storsjö --- libavformat/rtmpproto.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/rtmpproto.c b/libavformat/rtmpproto.c index 52dc45f752..02fbcc420f 100644 --- a/libavformat/rtmpproto.c +++ b/libavformat/rtmpproto.c @@ -706,7 +706,7 @@ static int gen_play(URLContext *s, RTMPContext *rt) ff_amf_write_number(&p, ++rt->nb_invokes); ff_amf_write_null(&p); ff_amf_write_string(&p, rt->playpath); - ff_amf_write_number(&p, rt->live); + ff_amf_write_number(&p, rt->live * 1000); return rtmp_send_packet(rt, &pkt, 1); }