diff mbox

[FFmpeg-devel] lavf/http: Reset encoding on redirect

Message ID CAB0OVGqzPkaEEciU-y3de8Y7Ra1LHCQUZtEF8LvU5EmGfwU+ig@mail.gmail.com
State Superseded
Headers show

Commit Message

Carl Eugen Hoyos Sept. 14, 2017, 9:27 p.m. UTC
Hi!

Attached patch fixes ticket #6666.

Please comment, Carl Eugen

Comments

Michael Niedermayer Sept. 15, 2017, 4:32 p.m. UTC | #1
On Thu, Sep 14, 2017 at 11:27:15PM +0200, Carl Eugen Hoyos wrote:
> Hi!
> 
> Attached patch fixes ticket #6666.
> 
> Please comment, Carl Eugen

>  http.c |    1 +
>  1 file changed, 1 insertion(+)
> 204665a4354f6df3d79f81535a6cef92d8720992  0001-lavf-http-Reset-encoding-on-redirect.patch
> From 479e3b2097a73a918f0c62cb6e3d661f9e71c5d0 Mon Sep 17 00:00:00 2001
> From: Carl Eugen Hoyos <ceffmpeg@gmail.com>
> Date: Thu, 14 Sep 2017 23:21:53 +0200
> Subject: [PATCH] lavf/http: Reset encoding on redirect.
> 
> Fixes ticket #6666.
> ---
>  libavformat/http.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/libavformat/http.c b/libavformat/http.c
> index 30890bb..d835f22 100644
> --- a/libavformat/http.c
> +++ b/libavformat/http.c
> @@ -287,6 +287,7 @@ redo:
>          memset(&s->auth_state, 0, sizeof(s->auth_state));
>          attempts         = 0;
>          location_changed = 0;
> +        s->compressed    = 0;
>          goto redo;
>      }
>      return 0;

needs
#if CONFIG_ZLIB

[...]
Carl Eugen Hoyos Sept. 15, 2017, 5:08 p.m. UTC | #2
2017-09-15 18:32 GMT+02:00 Michael Niedermayer <michael@niedermayer.cc>:
> On Thu, Sep 14, 2017 at 11:27:15PM +0200, Carl Eugen Hoyos wrote:
>> Hi!
>>
>> Attached patch fixes ticket #6666.
>>
>> Please comment, Carl Eugen
>
>>  http.c |    1 +
>>  1 file changed, 1 insertion(+)
>> 204665a4354f6df3d79f81535a6cef92d8720992  0001-lavf-http-Reset-encoding-on-redirect.patch
>> From 479e3b2097a73a918f0c62cb6e3d661f9e71c5d0 Mon Sep 17 00:00:00 2001
>> From: Carl Eugen Hoyos <ceffmpeg@gmail.com>
>> Date: Thu, 14 Sep 2017 23:21:53 +0200
>> Subject: [PATCH] lavf/http: Reset encoding on redirect.
>>
>> Fixes ticket #6666.
>> ---
>>  libavformat/http.c |    1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/libavformat/http.c b/libavformat/http.c
>> index 30890bb..d835f22 100644
>> --- a/libavformat/http.c
>> +++ b/libavformat/http.c
>> @@ -287,6 +287,7 @@ redo:
>>          memset(&s->auth_state, 0, sizeof(s->auth_state));
>>          attempts         = 0;
>>          location_changed = 0;
>> +        s->compressed    = 0;
>>          goto redo;
>>      }
>>      return 0;
>
> needs
> #if CONFIG_ZLIB

I pushed a patch today that was ignored here, Clement kindly
fixed the zlib issue.
(Imo, moving the second condition in the file so that compressed
is always available would simplify the code.)

Thank you, Carl Eugen
diff mbox

Patch

From 479e3b2097a73a918f0c62cb6e3d661f9e71c5d0 Mon Sep 17 00:00:00 2001
From: Carl Eugen Hoyos <ceffmpeg@gmail.com>
Date: Thu, 14 Sep 2017 23:21:53 +0200
Subject: [PATCH] lavf/http: Reset encoding on redirect.

Fixes ticket #6666.
---
 libavformat/http.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/libavformat/http.c b/libavformat/http.c
index 30890bb..d835f22 100644
--- a/libavformat/http.c
+++ b/libavformat/http.c
@@ -287,6 +287,7 @@  redo:
         memset(&s->auth_state, 0, sizeof(s->auth_state));
         attempts         = 0;
         location_changed = 0;
+        s->compressed    = 0;
         goto redo;
     }
     return 0;
-- 
1.7.10.4