Issue #16986: ElementTree now correctly parses a string input not only when
an internal XML encoding is UTF-8 or US-ASCII.
diff --git a/Modules/pyexpat.c b/Modules/pyexpat.c
index 022b0cb..4750225 100644
--- a/Modules/pyexpat.c
+++ b/Modules/pyexpat.c
@@ -1937,6 +1937,7 @@
capi.SetUnknownEncodingHandler = XML_SetUnknownEncodingHandler;
capi.SetUserData = XML_SetUserData;
capi.SetStartDoctypeDeclHandler = XML_SetStartDoctypeDeclHandler;
+ capi.SetEncoding = XML_SetEncoding;
/* export using capsule */
capi_object = PyCapsule_New(&capi, PyExpat_CAPSULE_NAME, NULL);