shadowsocks-rust 1.24.0

shadowsocks is a fast tunnel proxy that helps you bypass firewalls.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use log::info;
use std::io;
use tokio::signal::ctrl_c;

/// Create a monitor future for signals
///
/// It will exit when received Ctrl-C.
pub async fn create_signal_monitor() -> io::Result<()> {
    let _ = ctrl_c().await;
    info!("received CTRL-C, exiting");

    Ok(())
}