diff options
author | Sunil Nimmagadda <sunil@nimmagadda.net> | 2024-01-23 20:50:24 +0530 |
---|---|---|
committer | Sunil Nimmagadda <sunil@nimmagadda.net> | 2024-01-23 20:50:24 +0530 |
commit | d9170bd0853b82d74a6108cfa84f74a2582fbfa8 (patch) | |
tree | a9f604a840bf756fa9970dd4e445662844c49087 | |
parent | f2d7b7aa9d8a5f10dca015b7262c4fdd2d6102ac (diff) |
Note about as_chunks API.
-rw-r--r-- | src/vrrpv2.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/vrrpv2.rs b/src/vrrpv2.rs index 6fc80a3..e0f45a6 100644 --- a/src/vrrpv2.rs +++ b/src/vrrpv2.rs @@ -163,6 +163,7 @@ pub fn from_bytes(bytes: &[u8]) -> Result<VRRPv2, VRRPv2Error> { Ok(vrrpv2) } +/// TODO: as_chunks is nicer but not stabilised yet. fn checksum(bytes: &[u8]) -> u16 { let mut sum: u32 = 0; for chunk in bytes.chunks(2) { |