Use write_all and read_exact
While local connections are unlikely to run into problems or block on writing or reading, we want to keep writing or reading the message instead of returning an error.
Just something that clippy found. While the project probably doesn't want to worry about a clean report from it, this does seem like it could cause issues in edge cases.
Edited by Carlos Martín Nieto