closes #626: M1440677

This commit is contained in:
Cameron Kaiser 2020-09-27 16:21:22 -07:00
parent 92be8e3bec
commit 81acd2b99d
1 changed files with 6 additions and 3 deletions

View File

@ -485,10 +485,13 @@ nsMIMEHeaderParamImpl::DoParameterInternal(const char *aHeaderValue,
if (*str != '"') { if (*str != '"') {
// The value is a token, not a quoted string. // The value is a token, not a quoted string.
valueStart = str; valueStart = str;
for (valueEnd = str; for (valueEnd = str; *valueEnd && *valueEnd != ';'; valueEnd++) {
*valueEnd && !nsCRT::IsAsciiSpace (*valueEnd) && *valueEnd != ';';
valueEnd++)
; ;
}
// ignore trailing whitespace:
while (valueEnd > valueStart && nsCRT::IsAsciiSpace(*(valueEnd - 1))) {
valueEnd--;
}
str = valueEnd; str = valueEnd;
} else { } else {
isQuotedString = true; isQuotedString = true;