From 61f6cca2954fcaded11e226527e2173092288e76 Mon Sep 17 00:00:00 2001 From: illegitimate-egg Date: Sun, 9 Mar 2025 00:53:49 +0000 Subject: [PATCH] Catastrophically bad bug discovered, string write was writing zeroes instead of spaces (null terminators laugh in the face of god when he farts) --- src/utils.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/utils.rs b/src/utils.rs index c30c121..8a88ec3 100644 --- a/src/utils.rs +++ b/src/utils.rs @@ -269,9 +269,10 @@ mod tests { assert_eq!( client_disconnect("test string"), [ - 14, 116, 101, 115, 116, 32, 115, 116, 114, 105, 110, 103, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 + 14, 116, 101, 115, 116, 32, 115, 116, 114, 105, 110, 103, 32, 32, 32, 32, 32, 32, + 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, + 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, + 32, 32, 32, 32, 32 ] ); }