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

Unified Diff: third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp

Issue 1843863002: Avoid crash during PaintController::showDebugData() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp b/third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp
index 6451c65bccb4e53add10c2257a436430dbb35b2b..bfdf1493246dcdf0406668549653524eef1f31b6 100644
--- a/third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp
+++ b/third_party/WebKit/Source/platform/graphics/paint/PaintController.cpp
@@ -563,8 +563,10 @@ WTF::String PaintController::displayItemListAsDebugString(const DisplayItemList&
stringBuilder.append(",\n");
stringBuilder.append(String::format("{index: %d, ", (int)i));
displayItem.dumpPropertiesAsDebugString(stringBuilder);
- stringBuilder.append(", cacheIsValid: ");
- stringBuilder.append(clientCacheIsValid(displayItem.client()) ? "true" : "false");
+ if (displayItem.hasValidClient()) {
+ stringBuilder.append(", cacheIsValid: ");
+ stringBuilder.append(clientCacheIsValid(displayItem.client()) ? "true" : "false");
+ }
stringBuilder.append('}');
}
return stringBuilder.toString();
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698