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

Unified Diff: third_party/WebKit/Source/core/svg/SVGParsingError.cpp

Issue 1642463004: Extended error reporting for SVG path parsing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: "path flag" -> "arc flag" Created 4 years, 11 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: third_party/WebKit/Source/core/svg/SVGParsingError.cpp
diff --git a/third_party/WebKit/Source/core/svg/SVGParsingError.cpp b/third_party/WebKit/Source/core/svg/SVGParsingError.cpp
index da2345ddc9f97f47dccb3a273603c990d72bf5a7..189c4131c3975d1a41a0d3f5b66be74cd818454b 100644
--- a/third_party/WebKit/Source/core/svg/SVGParsingError.cpp
+++ b/third_party/WebKit/Source/core/svg/SVGParsingError.cpp
@@ -28,14 +28,20 @@ std::pair<const char*, const char*> messageForStatus(SVGParseStatus status)
switch (status) {
case SVGParseStatus::TrailingGarbage:
return std::make_pair("Trailing garbage, ", ".");
+ case SVGParseStatus::ExpectedArcFlag:
+ return std::make_pair("Expected arc flag ('0' or '1'), ", ".");
case SVGParseStatus::ExpectedBoolean:
return std::make_pair("Expected 'true' or 'false', ", ".");
case SVGParseStatus::ExpectedEnumeration:
return std::make_pair("Unrecognized enumerated value, ", ".");
case SVGParseStatus::ExpectedLength:
return std::make_pair("Expected length, ", ".");
+ case SVGParseStatus::ExpectedMoveToCommand:
+ return std::make_pair("Expected moveto path command ('M' or 'm'), ", ".");
case SVGParseStatus::ExpectedNumber:
return std::make_pair("Expected number, ", ".");
+ case SVGParseStatus::ExpectedPathCommand:
+ return std::make_pair("Expected path command, ", ".");
case SVGParseStatus::NegativeValue:
return std::make_pair("A negative value is not valid. (", ")");
case SVGParseStatus::ParsingFailed:
« no previous file with comments | « third_party/WebKit/Source/core/svg/SVGParsingError.h ('k') | third_party/WebKit/Source/core/svg/SVGPath.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698