From 5972678db845fe1f95214d72e0732d2a5128ef01 Mon Sep 17 00:00:00 2001 From: Rodrigo Arias Mallo Date: Thu, 1 May 2025 00:37:57 +0200 Subject: Allow whitespaces before separator --- src/misc.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/misc.h b/src/misc.h index 3b16566d..81c109c2 100644 --- a/src/misc.h +++ b/src/misc.h @@ -59,7 +59,9 @@ static inline void a_Misc_parse_content_disposition(const char *disposition, cha return; } - /* FIXME: what about "attachment ; filename=foo"? */ + /* Skip blanks like "attachment ; ..." */ + while (*s == ' ' || *s == '\t') + s++; /* Stop if the terminator is not ; */ if (*s != ';') -- cgit v1.2.3