rustfmt: add trailing commas in match arms, set fn call to block stle (#85)
This commit is contained in:
committed by
Carl Lerche
parent
de1edf4873
commit
f7d14861e5
@@ -27,11 +27,12 @@ pub fn main() {
|
||||
let _ = env_logger::init();
|
||||
|
||||
let tls_client_config = std::sync::Arc::new({
|
||||
let mut c = rustls::ClientConfig::new();
|
||||
c.root_store.add_server_trust_anchors(&webpki_roots::TLS_SERVER_ROOTS);
|
||||
c.alpn_protocols.push(ALPN_H2.to_owned());
|
||||
c
|
||||
});
|
||||
let mut c = rustls::ClientConfig::new();
|
||||
c.root_store
|
||||
.add_server_trust_anchors(&webpki_roots::TLS_SERVER_ROOTS);
|
||||
c.alpn_protocols.push(ALPN_H2.to_owned());
|
||||
c
|
||||
});
|
||||
|
||||
// Sync DNS resolution.
|
||||
let addr = "http2.akamai.com:443"
|
||||
|
||||
@@ -36,10 +36,10 @@ impl Future for Process {
|
||||
match try_ready!(self.body.poll()) {
|
||||
Some(chunk) => {
|
||||
println!("GOT CHUNK = {:?}", chunk);
|
||||
}
|
||||
},
|
||||
None => {
|
||||
self.trailers = true;
|
||||
}
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
extern crate bytes;
|
||||
extern crate env_logger;
|
||||
extern crate futures;
|
||||
@@ -57,8 +56,9 @@ pub fn main() {
|
||||
|
||||
Ok(())
|
||||
}).and_then(|_| {
|
||||
println!("~~~~~~~~~~~~~~~~~~~~~~~~~~~ H2 connection CLOSE !!!!!! \
|
||||
~~~~~~~~~~~");
|
||||
println!(
|
||||
"~~~~~~~~~~~~~~~~~~~~~~~~~~~ H2 connection CLOSE !!!!!! ~~~~~~~~~~~"
|
||||
);
|
||||
Ok(())
|
||||
})
|
||||
})
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
extern crate bytes;
|
||||
extern crate env_logger;
|
||||
extern crate futures;
|
||||
@@ -49,8 +48,9 @@ pub fn main() {
|
||||
|
||||
Ok(())
|
||||
}).and_then(|_| {
|
||||
println!("~~~~~~~~~~~~~~~~~~~~~~~~~~~ H2 connection CLOSE !!!!!! \
|
||||
~~~~~~~~~~~");
|
||||
println!(
|
||||
"~~~~~~~~~~~~~~~~~~~~~~~~~~~ H2 connection CLOSE !!!!!! ~~~~~~~~~~~"
|
||||
);
|
||||
Ok(())
|
||||
})
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user