1 2 3 4 5 6 7
use std::io; fn main() -> io::Result<()> { let port = freeport::get_free_port()?; println!("free port: {}", port); Ok(()) }