mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-07-29 11:41:22 +03:00
don't override existing encoding specified before starting
* parser.c: don't override existing encoding specified before starting xmlParseDocument() Daniel
This commit is contained in:
@ -1,3 +1,8 @@
|
||||
Sun Jul 29 07:18:53 EDT 2001 Daniel Veillard <Daniel.Veillard@imag.fr>
|
||||
|
||||
* parser.c: don't override existing encoding specified before
|
||||
starting xmlParseDocument()
|
||||
|
||||
Sat Jul 28 13:33:10 EDT 2001 Daniel Veillard <Daniel.Veillard@imag.fr>
|
||||
|
||||
* include/libxml/xmlwin32version.h: reinserted, needed for
|
||||
|
2
parser.c
2
parser.c
@ -7297,6 +7297,7 @@ xmlParseDocument(xmlParserCtxtPtr ctxt) {
|
||||
if ((ctxt->sax) && (ctxt->sax->setDocumentLocator))
|
||||
ctxt->sax->setDocumentLocator(ctxt->userData, &xmlDefaultSAXLocator);
|
||||
|
||||
if (ctxt->encoding == XML_CHAR_ENCODING_NONE) {
|
||||
/*
|
||||
* Get the 4 first bytes and decode the charset
|
||||
* if enc != XML_CHAR_ENCODING_NONE
|
||||
@ -7310,6 +7311,7 @@ xmlParseDocument(xmlParserCtxtPtr ctxt) {
|
||||
if (enc != XML_CHAR_ENCODING_NONE) {
|
||||
xmlSwitchEncoding(ctxt, enc);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (CUR == 0) {
|
||||
|
Reference in New Issue
Block a user