diff --git a/src/uu/ptx/src/ptx.rs b/src/uu/ptx/src/ptx.rs index 64a5e2bac..28d5e880a 100644 --- a/src/uu/ptx/src/ptx.rs +++ b/src/uu/ptx/src/ptx.rs @@ -501,7 +501,7 @@ fn get_output_chunks( // and get the string. let before_str: String = all_before[before_beg..before_end].iter().collect(); before.push_str(&before_str); - assert!(max_before_size >= before.len()); + assert!(max_before_size >= before.chars().count()); // the after chunk