Merge pull request #557 from manupap1/rtsp_fix

Fixed bug in rtsp streaming caused by a bad string concatenation
This commit is contained in:
Andrew Bauer committed 2014-11-06 07:12:00 -06:00
commit 22a0daaac8
1 file changed
+10 -1
+10 -1
View File
@@ -414,7 +414,16 @@ int RtspThread::run()
if ( mFormatContext->streams[i]->codec->codec_type == CODEC_TYPE_VIDEO )
#endif
{
trackUrl += "/"+mediaDesc->getControlUrl();
// Check if control Url is absolute or relative
std::string controlUrl = mediaDesc->getControlUrl();
if (std::equal(trackUrl.begin(), trackUrl.end(), controlUrl.begin()))
{
trackUrl = controlUrl;
}
else
{
trackUrl += "/" + controlUrl;
}
rtpClock = mediaDesc->getClock();
codecId = mFormatContext->streams[i]->codec->codec_id;
// Hackery pokery