[FFmpeg-devel] HTTP redirect 307 of an specified HLS url is not stored after HTTP connexion

Sidney N'Guessan sidney.nguessan at gmail.com
Tue Jun 25 16:35:34 CEST 2013


 If there is a HTTP redirect 307 on a specified url, the redirect is
 followed during the http connexion but is not stored.

 In my compagny, TV streaming is done through HLS and load balancing. For a
 channel, the stream URL is forward to a temporary redirect.

 Ex:
 wget http://our-server/CH1/CH1.m3u8
 --2013-06-25 16:00:59--  http://our-server/CH1/CH1.m3u8
 Connecting to our-server:80... connected.
 HTTP request sent, awaiting response... 307 Temporary Redirect
 Location: http://our-
 server:80/CH1/kac3trwi5qcqy5iiartgtbfizjqet2ii/0000150/GlobalHlsManifest.
m3u8
 [following]
 --2013-06-25 16:00:59--  http://our-
 server/CH1/kac3trwi5qcqy5iiartgtbfizjqet2ii/0000150/GlobalHlsManifest.m3u8
 Connecting to our-server:80... connected.
 HTTP request sent, awaiting response... 200 OK


 In our case, ffplay does not play the m3u8 because the URL sent to the HLS
 stack is the same as give in parameter but not the real URL (redirected)
 and the result is 404.

 /usr/bin/ffplay http://our-server/CH1/CH1.m3u8
 avplay version 0.8.5-4:0.8.5-0ubuntu0.12.04.1, Copyright (c) 2003-2012 the
 Libav developers
   built on Jan 24 2013 18:01:36 with gcc 4.6.3
 [http @ 0x7f702c0043c0] HTTP error 404 Not Found
 http://our-server/CH1/CH1.m3u8: Input/output error

In attachment, I have fix this bug.

 Sidney.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: follow-http-redirect.patch
Type: application/octet-stream
Size: 2911 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20130625/60572f5a/attachment.obj>


More information about the ffmpeg-devel mailing list