jyavenard

Untitled

Dec 26th, 2012
185
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.71 KB | None | 0 0
  1. diff --git a/mythtv/libs/libmythtv/HLS/httplivestreambuffer.cpp b/mythtv/libs/libmythtv/HLS/httplivestreambuffer.cpp
  2. index 04c8097..50615cc 100644
  3. --- a/mythtv/libs/libmythtv/HLS/httplivestreambuffer.cpp
  4. +++ b/mythtv/libs/libmythtv/HLS/httplivestreambuffer.cpp
  5. @@ -458,7 +458,7 @@ public:
  6. int count = NumSegments();
  7. for (int i = 0; i < count; i++)
  8. {
  9. - HLSSegment *segment = GetSegment(i);
  10. + HLSSegment *segment = GetSegment(i);
  11. segment->Lock();
  12. if (segment->Size() > 0)
  13. {
  14. @@ -2163,7 +2163,9 @@ int HLSRingBuffer::ParseM3U8(const QByteArray *buffer, StreamsList *streams)
  15. }
  16. else
  17. {
  18. - HLSStream *hls = ParseStreamInformation(line, uri);
  19. + // Line may be percent encoded
  20. + QString url = QUrl::fromEncoded (uri.toAscii()).toString();
  21. + HLSStream *hls = ParseStreamInformation(line, url);
  22. if (hls)
  23. {
  24. /* Download playlist file from server */
  25. @@ -2259,7 +2261,9 @@ int HLSRingBuffer::ParseM3U8(const QByteArray *buffer, StreamsList *streams)
  26. err = ParseEndList(hls);
  27. else if (!line.startsWith(QLatin1String("#")) && !line.isEmpty())
  28. {
  29. - hls->AddSegment(segment_duration, title, line);
  30. + // Line may be percent encoded
  31. + QString url = QUrl::fromEncoded (line.toAscii()).toString();
  32. + hls->AddSegment(segment_duration, title, url);
  33. segment_duration = -1; /* reset duration */
  34. title = "";
  35. }
Advertisement
Add Comment
Please, Sign In to add comment