1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-10-26 00:37:43 +03:00

541335 HTML avoid creating 2 head or 2 body element

* HTMLparser.c: check when we see an head or a body tag and avoid
  autogenerating them
* include/libxml/parser.h: the values for ctxt->html change depending
  on the head or body tags being seen
This commit is contained in:
Daniel Veillard
2009-08-24 12:50:23 +02:00
parent 6339c1a886
commit 029a04d265
2 changed files with 23 additions and 8 deletions

View File

@@ -190,7 +190,10 @@ struct _xmlParserCtxt {
const xmlChar *version; /* the XML version string */
const xmlChar *encoding; /* the declared encoding, if any */
int standalone; /* standalone document */
int html; /* an HTML(1)/Docbook(2) document */
int html; /* an HTML(1)/Docbook(2) document
* 3 is HTML after <head>
* 10 is HTML after <body>
*/
/* Input stream stack */
xmlParserInputPtr input; /* Current input stream */