Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(589)

Unified Diff: Source/core/css/resolver/FontBuilder.cpp

Issue 333163004: Remove explicit bounds check from CSSValueList::item (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: address comment Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/css/resolver/FontBuilder.cpp
diff --git a/Source/core/css/resolver/FontBuilder.cpp b/Source/core/css/resolver/FontBuilder.cpp
index 9de7131f88c83e1a5cd87023769eaad8902f3197..a03eecefa8e7adb9c1eb07f2463de3ce4cb69092 100644
--- a/Source/core/css/resolver/FontBuilder.cpp
+++ b/Source/core/css/resolver/FontBuilder.cpp
@@ -403,7 +403,7 @@ void FontBuilder::setFontVariantLigaturesValue(CSSValue* value)
if (value->isValueList()) {
CSSValueList* valueList = toCSSValueList(value);
for (size_t i = 0; i < valueList->length(); ++i) {
- CSSValue* item = valueList->itemWithoutBoundsCheck(i);
+ CSSValue* item = valueList->item(i);
ASSERT(item->isPrimitiveValue());
if (item->isPrimitiveValue()) {
CSSPrimitiveValue* primitiveValue = toCSSPrimitiveValue(item);
@@ -511,7 +511,7 @@ void FontBuilder::setFeatureSettingsValue(CSSValue* value)
RefPtr<FontFeatureSettings> settings = FontFeatureSettings::create();
int len = list->length();
for (int i = 0; i < len; ++i) {
- CSSValue* item = list->itemWithoutBoundsCheck(i);
+ CSSValue* item = list->item(i);
if (!item->isFontFeatureValue())
continue;
CSSFontFeatureValue* feature = toCSSFontFeatureValue(item);
« no previous file with comments | « Source/core/css/resolver/FilterOperationResolver.cpp ('k') | Source/core/css/resolver/StyleBuilderConverter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698