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

Unified Diff: Source/core/xml/XMLHttpRequest.cpp

Issue 19845004: Do not normalize into NFC the values of form fields (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add normalizeAndEncode() Created 7 years, 5 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: Source/core/xml/XMLHttpRequest.cpp
diff --git a/Source/core/xml/XMLHttpRequest.cpp b/Source/core/xml/XMLHttpRequest.cpp
index 91c32f796d93f117d91248f84212ee85f1019796..01089b1c9ea6213daa6eebc8e317fc3c5b82fa69 100644
--- a/Source/core/xml/XMLHttpRequest.cpp
+++ b/Source/core/xml/XMLHttpRequest.cpp
@@ -573,7 +573,7 @@ void XMLHttpRequest::send(Document* document, ExceptionCode& ec)
String body = createMarkup(document);
// FIXME: This should use value of document.inputEncoding to determine the encoding to use.
- m_requestEntityBody = FormData::create(UTF8Encoding().encode(body, WTF::EntitiesForUnencodables));
+ m_requestEntityBody = FormData::create(UTF8Encoding().normalizeAndEncode(body, WTF::EntitiesForUnencodables));
if (m_upload)
m_requestEntityBody->setAlwaysStream(true);
}
@@ -595,7 +595,7 @@ void XMLHttpRequest::send(const String& body, ExceptionCode& ec)
m_requestHeaders.set("Content-Type", contentType);
}
- m_requestEntityBody = FormData::create(UTF8Encoding().encode(body, WTF::EntitiesForUnencodables));
+ m_requestEntityBody = FormData::create(UTF8Encoding().normalizeAndEncode(body, WTF::EntitiesForUnencodables));
if (m_upload)
m_requestEntityBody->setAlwaysStream(true);
}

Powered by Google App Engine
This is Rietveld 408576698