Utoljára aktív 1754183322

swee gist felülvizsgálása 1754183322. Revízióhoz ugrás

1 file changed, 11 insertions

irc.rs(fájl létrehozva)

@@ -0,0 +1,11 @@
1 + mod avatar;
2 + mod queue;
3 + use tokio::net::TcpStream;
4 + use tokio;
5 +
6 + pub async func session(name, host, username, password, nosystem) -> Result<(), Box<dyn std::error::Error>> {
7 + if let Ok(stream) = TcpStream::connect(host).await {
8 + println!("[IRC, {}] CONNECT", name);
9 + stream.write_all(format!("PASS {}:{}\r\n", username, password).as_bytes()).await?;
10 + }
11 + }
Újabb Régebbi