From 59cd17d4b5b1eff2847a954012eb916db4ef5116 Mon Sep 17 00:00:00 2001 From: Fuwn Date: Sun, 23 May 2021 13:51:20 +0000 Subject: docs(global): add new documentation --- crates/whirl_server/src/packet_parser.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'crates/whirl_server/src/packet_parser.rs') diff --git a/crates/whirl_server/src/packet_parser.rs b/crates/whirl_server/src/packet_parser.rs index bfeba9e..79293cb 100644 --- a/crates/whirl_server/src/packet_parser.rs +++ b/crates/whirl_server/src/packet_parser.rs @@ -3,13 +3,13 @@ use bytes::BytesMut; -/// Read all commands from the given buffer. +/// Read all commands from the given `buffer`. /// /// # Process -/// 1. Get a command from `buffer` based on first byte. +/// 1. Read a command from `buffer` based on it's first byte. /// 2. Push command to `commands`. /// 3. Remove command from `buffer`. -/// 4. Iterate and do this for all commands within `buffer`. +/// 4. Iterate and do this for the remaining commands within `buffer`. pub fn parse_commands_from_packet(mut buffer: BytesMut) -> Vec { let mut commands: Vec = Vec::new(); trace!("initial buffer: {:?}, length: {}", buffer, buffer.len()); -- cgit v1.2.3