mirror of
https://github.com/async-rs/async-std.git
synced 2025-04-24 09:16:46 +00:00
Pass in error to log line with placeholder
This commit is contained in:
parent
c5631996c9
commit
50e7cf0e43
1 changed files with 1 additions and 1 deletions
|
@ -124,7 +124,7 @@ async fn accept_loop(addr: impl ToSocketAddrs) -> Result<()> {
|
||||||
let stream = match result {
|
let stream = match result {
|
||||||
Err(ref e) if is_connection_error(e) => continue, // 1
|
Err(ref e) if is_connection_error(e) => continue, // 1
|
||||||
Err(e) => {
|
Err(e) => {
|
||||||
eprintln!("Error: {}. Pausing for 500ms."); // 3
|
eprintln!("Error: {}. Pausing for 500ms.", e); // 3
|
||||||
task::sleep(Duration::from_millis(500)).await; // 2
|
task::sleep(Duration::from_millis(500)).await; // 2
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue