From 5c4ced773de446f9473962b5189a599ee4e54de8 Mon Sep 17 00:00:00 2001 From: Jacek Jendrzej Date: Thu, 16 May 2019 19:43:08 +0200 Subject: [PATCH] streamts: supplement to 086578fdb2a0133953b98171106699e8b04da8ea --- src/driver/streamts.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/driver/streamts.cpp b/src/driver/streamts.cpp index b98646315..0f0edcc6f 100644 --- a/src/driver/streamts.cpp +++ b/src/driver/streamts.cpp @@ -858,7 +858,7 @@ bool CStreamStream::Open() snprintf(ifcx->filename, sizeof(ifcx->filename), "%s", channel->getUrl().c_str()); av_dump_format(ifcx, 0, ifcx->filename, 0); #else - snprintf(ifcx->url, channel->getUrl().size() + 1, "%s", channel->getUrl().c_str()); + ifcx->url = av_strdup(!channel->getUrl().empty() ? channel->getUrl().c_str() : ""); av_dump_format(ifcx, 0, ifcx->url, 0); #endif