chore: style
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
use std::net::{TcpStream};
|
use std::net::TcpStream;
|
||||||
use std::io::{Read, Write};
|
use std::io::{ Read, Write };
|
||||||
use std::str::from_utf8;
|
use std::str::from_utf8;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
@@ -11,7 +11,7 @@ fn main() {
|
|||||||
stream.write(msg).unwrap();
|
stream.write(msg).unwrap();
|
||||||
println!("Sent Hello, awaiting reply...");
|
println!("Sent Hello, awaiting reply...");
|
||||||
|
|
||||||
let mut data = [0 as u8; 6]; // using 6 byte buffer
|
let mut data = [0_u8; 6]; // using 6 byte buffer
|
||||||
match stream.read_exact(&mut data) {
|
match stream.read_exact(&mut data) {
|
||||||
Ok(_) => {
|
Ok(_) => {
|
||||||
if &data == msg {
|
if &data == msg {
|
||||||
|
|||||||
Reference in New Issue
Block a user