| Index: third_party/WebKit/Source/core/frame/csp/ContentSecurityPolicy.cpp
|
| diff --git a/third_party/WebKit/Source/core/frame/csp/ContentSecurityPolicy.cpp b/third_party/WebKit/Source/core/frame/csp/ContentSecurityPolicy.cpp
|
| index 45a274056be1cfd24fb2b7ad848dd124e8c9e181..7cdbb53cb8b237c09276f2d5dc9c28cf1efbbf3d 100644
|
| --- a/third_party/WebKit/Source/core/frame/csp/ContentSecurityPolicy.cpp
|
| +++ b/third_party/WebKit/Source/core/frame/csp/ContentSecurityPolicy.cpp
|
| @@ -895,11 +895,12 @@ void ContentSecurityPolicy::reportViolation(const String& directiveText, const S
|
| cspReport->setString("effective-directive", violationData.effectiveDirective());
|
| cspReport->setString("original-policy", violationData.originalPolicy());
|
| cspReport->setString("blocked-uri", violationData.blockedURI());
|
| - if (!violationData.sourceFile().isEmpty() && violationData.lineNumber()) {
|
| - cspReport->setString("source-file", violationData.sourceFile());
|
| + if (violationData.lineNumber())
|
| cspReport->setNumber("line-number", violationData.lineNumber());
|
| + if (violationData.columnNumber())
|
| cspReport->setNumber("column-number", violationData.columnNumber());
|
| - }
|
| + if (!violationData.sourceFile().isEmpty())
|
| + cspReport->setString("source-file", violationData.sourceFile());
|
| cspReport->setNumber("status-code", violationData.statusCode());
|
|
|
| RefPtr<JSONObject> reportObject = JSONObject::create();
|
|
|