mirror of
https://github.com/tokio-rs/tokio.git
synced 2025-10-01 12:20:39 +00:00
doc: update README.md (#3806)
This commit is contained in:
parent
44a070d1b4
commit
5ed84e1cd8
@ -66,7 +66,7 @@ use tokio::io::{AsyncReadExt, AsyncWriteExt};
|
|||||||
|
|
||||||
#[tokio::main]
|
#[tokio::main]
|
||||||
async fn main() -> Result<(), Box<dyn std::error::Error>> {
|
async fn main() -> Result<(), Box<dyn std::error::Error>> {
|
||||||
let mut listener = TcpListener::bind("127.0.0.1:8080").await?;
|
let listener = TcpListener::bind("127.0.0.1:8080").await?;
|
||||||
|
|
||||||
loop {
|
loop {
|
||||||
let (mut socket, _) = listener.accept().await?;
|
let (mut socket, _) = listener.accept().await?;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user