mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
Auto merge of #16489 - jdm:http-response, r=asajeffrey
Show HTTP response headers in debug output. - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [x] These changes do not require tests because they are changing informative debug output. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16489) <!-- Reviewable:end -->
This commit is contained in:
commit
86aa4e89c5
1 changed files with 7 additions and 0 deletions
|
@ -1095,6 +1095,13 @@ fn http_network_fetch(request: &Request,
|
|||
Err(error) => return Response::network_error(error),
|
||||
};
|
||||
|
||||
if log_enabled!(log::LogLevel::Info) {
|
||||
info!("response for {}", url);
|
||||
for header in res.response.headers.iter() {
|
||||
info!(" - {}", header);
|
||||
}
|
||||
}
|
||||
|
||||
let mut response = Response::new(url.clone());
|
||||
response.status = Some(res.response.status);
|
||||
response.raw_status = Some((res.response.status_raw().0,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue