36 строки
1.6 KiB
Diff
36 строки
1.6 KiB
Diff
|
diff --git a/content/public/browser/resource_request_details.cc b/content/public/browser/resource_request_details.cc
|
||
|
index 0e790b68..0b5140a 100644
|
||
|
--- a/content/public/browser/resource_request_details.cc
|
||
|
+++ b/content/public/browser/resource_request_details.cc
|
||
|
@@ -22,6 +22,10 @@ ResourceRequestDetails::ResourceRequestDetails(const net::URLRequest* request,
|
||
|
has_certificate(has_certificate),
|
||
|
ssl_cert_status(request->ssl_info().cert_status),
|
||
|
socket_address(request->GetSocketAddress()) {
|
||
|
+ if (request->response_info().headers.get())
|
||
|
+ headers = new net::HttpResponseHeaders(
|
||
|
+ request->response_info().headers->raw_headers());
|
||
|
+
|
||
|
const ResourceRequestInfo* info = ResourceRequestInfo::ForRequest(request);
|
||
|
resource_type = info->GetResourceType();
|
||
|
http_response_code =
|
||
|
diff --git a/content/public/browser/resource_request_details.h b/content/public/browser/resource_request_details.h
|
||
|
index e54e2c0..d817176 100644
|
||
|
--- a/content/public/browser/resource_request_details.h
|
||
|
+++ b/content/public/browser/resource_request_details.h
|
||
|
@@ -10,6 +10,7 @@
|
||
|
#include "content/public/common/resource_type.h"
|
||
|
#include "net/base/host_port_pair.h"
|
||
|
#include "net/cert/cert_status_flags.h"
|
||
|
+#include "net/http/http_response_headers.h"
|
||
|
#include "net/url_request/url_request_status.h"
|
||
|
#include "url/gurl.h"
|
||
|
|
||
|
@@ -41,6 +42,7 @@ struct ResourceRequestDetails {
|
||
|
// HTTP response code. See HttpResponseHeaders::response_code().
|
||
|
// -1 if there are no response headers yet.
|
||
|
int http_response_code;
|
||
|
+ scoped_refptr<net::HttpResponseHeaders> headers;
|
||
|
};
|
||
|
|
||
|
// Details about a redirection of a resource request.
|