Daniel Lehman : msxml3: Make utf-8 the default encoding.
Alexandre Julliard
julliard at winehq.org
Mon Jan 31 15:55:18 CST 2022
Module: wine
Branch: master
Commit: 5260ab30cda07b896eaf8704890f7797dadd85f2
URL: https://source.winehq.org/git/wine.git/?a=commit;h=5260ab30cda07b896eaf8704890f7797dadd85f2
Author: Daniel Lehman <dlehman at esri.com>
Date: Wed Nov 24 08:33:06 2021 -0800
msxml3: Make utf-8 the default encoding.
Signed-off-by: Daniel Lehman <dlehman at esri.com>
Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/msxml3/domdoc.c | 3 +++
dlls/msxml3/tests/domdoc.c | 2 +-
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/dlls/msxml3/domdoc.c b/dlls/msxml3/domdoc.c
index 4013f106cc6..082d7950f8d 100644
--- a/dlls/msxml3/domdoc.c
+++ b/dlls/msxml3/domdoc.c
@@ -2603,6 +2603,9 @@ static char *xmldoc_encoding(IXMLDOMDocument3 *doc)
IXMLDOMNode_Release(node);
}
+ if (!encoding && (encoding = heap_alloc(sizeof("UTF-8"))))
+ strcpy(encoding, "UTF-8");
+
return encoding;
}
diff --git a/dlls/msxml3/tests/domdoc.c b/dlls/msxml3/tests/domdoc.c
index 761688c187b..ad4d255abe7 100644
--- a/dlls/msxml3/tests/domdoc.c
+++ b/dlls/msxml3/tests/domdoc.c
@@ -6636,7 +6636,7 @@ static void test_save(void)
{
ReadFile(hfile, buffer, sizeof(buffer), &read, NULL);
ok(read != 0, "could not read file\n");
- todo_wine ok(!memcmp(buffer, cheA, sizeof(cheA)-1), "got: %s\n", buffer);
+ ok(!memcmp(buffer, cheA, sizeof(cheA)-1), "got: %s\n", buffer);
CloseHandle(hfile);
DeleteFileA("test.xml");
More information about the wine-cvs
mailing list