Chunked encoding parser

This commit is contained in:
Tomasz Drwięga
2016-08-31 10:43:55 +02:00
parent 2a549386a6
commit bff847b90c
9 changed files with 355 additions and 24 deletions

View File

@@ -6,9 +6,7 @@ use https_fetch::*;
fn main() {
let client = Client::new().unwrap();
let rx = client.fetch(Url::new("github.com", 443, "/").unwrap(), Box::new(io::stdout())).unwrap();
let result = rx.recv().unwrap();
assert!(result.is_ok());
client.fetch(Url::new("github.com", 443, "/").unwrap(), Box::new(io::stdout()), |result| {
assert!(result.is_ok());
}).unwrap();
}