Reject duplicate keywords for 'text-decoration'. (Bug 470704) r+sr=bzbarsky

This commit is contained in:
L. David Baron 2008-12-23 09:06:58 -05:00
parent 4cda588725
commit 409bc375af
2 changed files with 6 additions and 2 deletions

View File

@ -7627,7 +7627,12 @@ CSSParserImpl::ParseTextDecoration(nsCSSValue& aValue)
PRInt32 index;
for (index = 0; index < 3; index++) {
if (ParseEnum(keyword, nsCSSProps::kTextDecorationKTable)) {
intValue |= keyword.GetIntValue();
PRInt32 newValue = keyword.GetIntValue();
if (newValue & intValue) {
// duplicate keyword is not allowed
return PR_FALSE;
}
intValue |= newValue;
}
else {
break;

View File

@ -26,7 +26,6 @@ var gKnownFails = {
"richness": [ " -0.01", "100.2", "108", "-3" ],
"stress": [ " -0.01", "100.2", "108", "-3" ],
"volume": [ " -0.01", "100.2", "108", "-3" ],
"text-decoration": [ "line-through blink line-through" ],
"stroke-miterlimit": [ "0.9", "0" ]
}