mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Add support for setting response header values (issue #246).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@246 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
@@ -446,14 +446,11 @@ class RequestProxy : public net::URLRequest::Delegate,
|
||||
|
||||
CefResponseImpl* responseImpl =
|
||||
static_cast<CefResponseImpl*>(response.get());
|
||||
scoped_refptr<net::HttpResponseHeaders> headers(
|
||||
new net::HttpResponseHeaders(
|
||||
responseImpl->GenerateResponseLine()));
|
||||
|
||||
ResourceResponseInfo info;
|
||||
info.content_length = static_cast<int64>(offset);
|
||||
info.mime_type = response->GetMimeType();
|
||||
info.headers = headers;
|
||||
info.headers = responseImpl->GetResponseHeaders();
|
||||
OnReceivedResponse(info, params->url);
|
||||
AsyncReadData();
|
||||
} else if (response->GetStatus() != 0) {
|
||||
@@ -462,14 +459,11 @@ class RequestProxy : public net::URLRequest::Delegate,
|
||||
|
||||
CefResponseImpl* responseImpl =
|
||||
static_cast<CefResponseImpl*>(response.get());
|
||||
scoped_refptr<net::HttpResponseHeaders> headers(
|
||||
new net::HttpResponseHeaders(
|
||||
responseImpl->GenerateResponseLine()));
|
||||
|
||||
ResourceResponseInfo info;
|
||||
info.content_length = 0;
|
||||
info.mime_type = response->GetMimeType();
|
||||
info.headers = headers;
|
||||
info.headers = responseImpl->GetResponseHeaders();
|
||||
OnReceivedResponse(info, params->url);
|
||||
AsyncReadData();
|
||||
}
|
||||
|
Reference in New Issue
Block a user