[FFmpeg-devel] [PATCH] avformat/rtmp: Increase filename size to allow for longer playpaths

Adam Wall wallboy at wallboy.ca
Thu Jan 30 13:55:55 EET 2025


The current filename length for the stream name when RTMP is acting as
a server is too short. Certain services such as Amazon IVS use very
long streamkeys (close to 500 characters) when using the new enhanced
RTMP multitrack feature.

When using software such as OBS that can utilize Amazon IVS multitrack
and specifying a custom RTMP server, where that server is FFmpeg RTMP
in listen mode, then the key that gets passed over the publish
commands exceeds the current 128 length limit, resulting in a "name
too long" error.

This commit simply increases the filename size to accomodate these
longer stream names.

Signed-off-by: Adam Wall <wallboy at wallboy.ca>
---
 libavformat/rtmpproto.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/rtmpproto.c b/libavformat/rtmpproto.c
index 4095ae9421..d34678144e 100644
--- a/libavformat/rtmpproto.c
+++ b/libavformat/rtmpproto.c
@@ -1943,7 +1943,7 @@ static int send_invoke_response(URLContext *s, RTMPPacket *pkt)
 {
     RTMPContext *rt = s->priv_data;
     double seqnum;
-    char filename[128];
+    char filename[1024];
     char command[64];
     int stringlen;
     char *pchar;
-- 
2.48.1



More information about the ffmpeg-devel mailing list