Index: Source/core/xml/XMLHttpRequest.cpp |
diff --git a/Source/core/xml/XMLHttpRequest.cpp b/Source/core/xml/XMLHttpRequest.cpp |
index 0133c246396b3a46e04566d65fcb0f683429f827..5d1979176606a13ed6a09d9ed92e6b2ea6dbbf97 100644 |
--- a/Source/core/xml/XMLHttpRequest.cpp |
+++ b/Source/core/xml/XMLHttpRequest.cpp |
@@ -914,6 +914,13 @@ void XMLHttpRequest::clearVariablesForLoading() |
{ |
m_decoder.clear(); |
+ if (m_responseDocumentParser) { |
+#if !ENABLE(OILPAN) |
+ m_responseDocumentParser->detach(); |
+#endif |
+ m_responseDocumentParser = nullptr; |
+ } |
+ |
m_finalResponseCharset = String(); |
} |
@@ -921,6 +928,9 @@ bool XMLHttpRequest::internalAbort() |
{ |
m_error = true; |
+ if (m_responseDocumentParser && m_responseDocumentParser->isStopped()) |
tyoshino (SeeGerritForStatus)
2014/09/01 05:06:05
I guess you wanted
!m_responseDocumentParser->isS
kouhei (in TOK)
2014/09/01 05:16:57
Done.
|
+ m_responseDocumentParser->stopParsing(); |
+ |
clearVariablesForLoading(); |
InspectorInstrumentation::didFailXHRLoading(executionContext(), this, this); |
@@ -971,7 +981,6 @@ void XMLHttpRequest::clearResponse() |
m_parsedResponse = false; |
m_responseDocument = nullptr; |
- m_responseDocumentParser = nullptr; |
m_responseBlob = nullptr; |
m_downloadedBlobLength = 0; |