fix: don't break long group names with non-ASCII characters

The fix is in mail-builder 0.4.4.
This commit is contained in:
link2xt
2025-07-24 21:11:39 +00:00
committed by l
parent dcdf30da35
commit 5476f69179
4 changed files with 29 additions and 4 deletions

View File

@@ -91,8 +91,11 @@ fn test_render_rfc724_mid() {
fn render_header_text(text: &str) -> String {
let mut output = Vec::<u8>::new();
// Some non-zero length of the header name.
let bytes_written = 20;
mail_builder::headers::text::Text::new(text.to_string())
.write_header(&mut output, 0)
.write_header(&mut output, bytes_written)
.unwrap();
String::from_utf8(output).unwrap()