We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
http_client.c http_client_onread_header函数里面对重定向进行了判断 ''' if(300 <= code && code < 400) { if(http_client_redirect_handler(http)) { code = http_client_request(http, http->parameters.method, http->parameters.uri, http->parameters.headers, http->parameters.n, http->parameters.msg, http->parameters.bytes, http->onreply, http->cbparam); if(0 != code) http_client_handle(http, code > 0 ? -code : code); return; } } ''' 但是这里并没有使用Location指定的url,http_client_redirect_handler函数里面仅仅是把Location指定的url保存到http->redirect.urls,应该进行如下修改 ''' http->redirect.urls[http->redirect.n++] = strdup(uri); //指向Location指定的url http->parameters.uri=http->redirect.urls[http->redirect.n-1]; '''
The text was updated successfully, but these errors were encountered:
No branches or pull requests
http_client.c http_client_onread_header函数里面对重定向进行了判断
'''
if(300 <= code && code < 400)
{
if(http_client_redirect_handler(http))
{
code = http_client_request(http, http->parameters.method, http->parameters.uri, http->parameters.headers, http->parameters.n, http->parameters.msg, http->parameters.bytes, http->onreply, http->cbparam);
if(0 != code)
http_client_handle(http, code > 0 ? -code : code);
return;
}
}
'''
但是这里并没有使用Location指定的url,http_client_redirect_handler函数里面仅仅是把Location指定的url保存到http->redirect.urls,应该进行如下修改
'''
http->redirect.urls[http->redirect.n++] = strdup(uri);
//指向Location指定的url
http->parameters.uri=http->redirect.urls[http->redirect.n-1];
'''
The text was updated successfully, but these errors were encountered: