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

Unified Diff: third_party/WebKit/Source/core/css/MediaQueryEvaluator.cpp

Issue 2806003002: Verify that constant vectors aren't invalidated during iteration. (Closed)
Patch Set: Created 3 years, 8 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/css/RuleSet.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/css/MediaQueryEvaluator.cpp
diff --git a/third_party/WebKit/Source/core/css/MediaQueryEvaluator.cpp b/third_party/WebKit/Source/core/css/MediaQueryEvaluator.cpp
index 823b91f198e5fbae00015ce26ed5b2c93cbf91e4..570e130f04b131b8c0907e86a455d8d342caa826 100644
--- a/third_party/WebKit/Source/core/css/MediaQueryEvaluator.cpp
+++ b/third_party/WebKit/Source/core/css/MediaQueryEvaluator.cpp
@@ -151,9 +151,12 @@ bool MediaQueryEvaluator::eval(
// Iterate over queries, stop if any of them eval to true (OR semantics).
bool result = false;
- for (size_t i = 0; i < queries.size() && !result; ++i)
+ for (size_t i = 0; i < queries.size() && !result; ++i) {
+ // TODO(sof): CHECK() added for crbug.com/699269 diagnosis, remove sooner.
+ CHECK_EQ(queries.data(), querySet->queryVector().data());
result = eval(queries[i].get(), viewportDependentMediaQueryResults,
deviceDependentMediaQueryResults);
+ }
return result;
}
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/css/RuleSet.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698