diff options
-rw-r--r-- | libavformat/rtmpproto.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/libavformat/rtmpproto.c b/libavformat/rtmpproto.c index e7e2479f04..64024259e2 100644 --- a/libavformat/rtmpproto.c +++ b/libavformat/rtmpproto.c @@ -1918,6 +1918,13 @@ static int send_invoke_response(URLContext *s, RTMPPacket *pkt) !strcmp(command, "publish")) { ret = ff_amf_read_string(&gbc, filename, sizeof(filename), &stringlen); + if (ret) { + if (ret == AVERROR(EINVAL)) + av_log(s, AV_LOG_ERROR, "Unable to parse stream name - name too long?\n"); + else + av_log(s, AV_LOG_ERROR, "Unable to parse stream name\n"); + return ret; + } // check with url if (s->filename) { pchar = strrchr(s->filename, '/'); |