Skip to content

Commit

Permalink
try encode web seed redirect location
Browse files Browse the repository at this point in the history
  • Loading branch information
ajax16384 committed Feb 28, 2024
1 parent 0982972 commit a8c6d63
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/web_peer_connection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -666,6 +666,7 @@ void web_peer_connection::handle_redirect(int const bytes_left)
file_index_t const file_index = m_file_requests.front().file_index;

location = aux::resolve_redirect_location(m_url, location);
location = maybe_url_encode(location);
#ifndef TORRENT_DISABLE_LOGGING
peer_log(peer_log_alert::info, "LOCATION", "%s", location.c_str());
#endif
Expand Down Expand Up @@ -735,6 +736,7 @@ void web_peer_connection::handle_redirect(int const bytes_left)
else
{
location = aux::resolve_redirect_location(m_url, location);
location = maybe_url_encode(location);
#ifndef TORRENT_DISABLE_LOGGING
peer_log(peer_log_alert::info, "LOCATION", "%s", location.c_str());
#endif
Expand Down

0 comments on commit a8c6d63

Please sign in to comment.