mirror of
https://github.com/transmission/transmission
synced 2025-02-08 15:34:44 +00:00
#4524 Redirects with https are broken
This commit is contained in:
parent
71c06d2953
commit
eb46c13d74
1 changed files with 1 additions and 3 deletions
|
@ -628,9 +628,7 @@ handle_request( struct evhttp_request * req, void * arg )
|
|||
}
|
||||
else if( strncmp( req->uri, server->url, strlen( server->url ) ) )
|
||||
{
|
||||
const char * protocol = "http";
|
||||
const char * host = evhttp_find_header( req->input_headers, "Host" );
|
||||
char * location = tr_strdup_printf( "%s://%s%sweb/", protocol, host, server->url );
|
||||
char * location = tr_strdup_printf( "%sweb/", server->url );
|
||||
evhttp_add_header( req->output_headers, "Location", location );
|
||||
send_simple_response( req, HTTP_MOVEPERM, NULL );
|
||||
tr_free( location );
|
||||
|
|
Loading…
Reference in a new issue