History

http: Handle 301/307 redirect requests, too

Patch by Mike Edenfield, kutulu at kutulu dot org Originally committed as revision 25651 to svn://svn.ffmpeg.org/ffmpeg/trunk

Mike Edenfield committed 16 years ago

Commit 7e35d851 parent 769b74a1 file · +2 −1Browse files

Unified · Split

libavformat/http.c+2−1
@@ -138,7 +138,8 @@ static int http_open_cnx(URLContext *h) · 137 unmodified lines
138138 } else
139139 goto fail;
140140 }
141− if ((s->http_code == 302 || s->http_code == 303) && location_changed == 1) {
141+ if ((s->http_code == 301 || s->http_code == 302 || s->http_code == 303 || s->http_code == 307)
142+ && location_changed == 1) {
142143 /* url moved, get next */
143144 url_close(hd);
144145 if (redirects++ >= MAX_REDIRECTS)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t