[−][src]Function linda::handle_connection
pub fn handle_connection(stream: TcpStream) -> Result<(), Box<dyn Error>>
Handles TcpStream connection
Writes requests coming from the TcpStream to a buffer Writes out the response for the corresponding request
Errors
Propagates errors up if:
- Was not able to read the stream into the buffer
- The request was invlid
- Was not able to write out response
- Was not able to flush the stream