1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-12-04 14:46:47 -05:00

[curl] Ask for password for http

This commit is contained in:
Witold Filipczyk 2023-07-01 09:28:57 +02:00
parent 9389e2f903
commit 36b802251d

View File

@ -400,12 +400,19 @@ http_curl_handle_error(struct connection *conn, CURLcode res)
{
if (res == CURLE_OK) {
char *url = http_curl_check_redirect(conn);
struct http_curl_connection_info *http = (struct http_curl_connection_info *)conn->info;
if (url) {
redirect_cache(conn->cached, url, 0, 0);
abort_connection(conn, connection_state(S_OK));
return;
}
if (http->code == 401L) {
add_auth_entry(conn->uri, "HTTP Auth", NULL, NULL, 0);
abort_connection(conn, connection_state(S_OK));
return;
}
abort_connection(conn, connection_state(S_OK));
return;
} else {