[FFmpeg-cvslog] lavf/http: Process HTTP header before sending response.

Stephan Holljes git at videolan.org
Sat Jun 6 12:51:41 CEST 2015


ffmpeg | branch: master | Stephan Holljes <klaxa1337 at googlemail.com> | Thu Jun  4 01:17:51 2015 +0200| [bbcee92b6d59adca054351c6e9e56bcb77ebda11] | committer: Nicolas George

lavf/http: Process HTTP header before sending response.

Signed-off-by: Stephan Holljes <klaxa1337 at googlemail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=bbcee92b6d59adca054351c6e9e56bcb77ebda11
---

 libavformat/http.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavformat/http.c b/libavformat/http.c
index 546741a..e51f524 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -318,10 +318,10 @@ static int http_listen(URLContext *h, const char *uri, int flags,
     if ((ret = ffurl_open(&s->hd, lower_url, AVIO_FLAG_READ_WRITE,
                           &h->interrupt_callback, options)) < 0)
         goto fail;
-    if ((ret = ffurl_write(s->hd, header, strlen(header))) < 0)
-        goto fail;
     if ((ret = http_read_header(h, &new_location)) < 0)
          goto fail;
+    if ((ret = ffurl_write(s->hd, header, strlen(header))) < 0)
+         goto fail;
     return 0;
 
 fail:



More information about the ffmpeg-cvslog mailing list