Index: Source/core/dom/Document.cpp |
diff --git a/Source/core/dom/Document.cpp b/Source/core/dom/Document.cpp |
index 8b7633901a08b68c521017b2fd2ff03441dd210d..199b5b2c0cfb44da621eafaf28364f26ab9d6a99 100644 |
--- a/Source/core/dom/Document.cpp |
+++ b/Source/core/dom/Document.cpp |
@@ -2557,8 +2557,11 @@ void Document::write(const SegmentedString& text, Document* ownerDocument) |
return; |
bool hasInsertionPoint = m_parser && m_parser->hasInsertionPoint(); |
- if (!hasInsertionPoint && m_ignoreDestructiveWriteCount) |
+ |
+ if (!hasInsertionPoint && m_ignoreDestructiveWriteCount) { |
+ addConsoleMessage(JSMessageSource, WarningMessageLevel, ExceptionMessages::failedToExecute("write", "Document", "It isn't possible to write into a document from an asynchronously-loaded external script unless it is explicitly opened.")); |
return; |
+ } |
if (!hasInsertionPoint) |
open(ownerDocument); |