1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-07-29 11:41:22 +03:00

do not output hexadecimal charrefs when serializing HTML since some

* encoding.c entities.c: do not output hexadecimal charrefs
  when serializing HTML since some version of Netscape can't
  grok it, generate decimal ones.
* result/HTML/doc3.htm: output changed due to previous test
* parserInternals.c: repair xmlKeepBlanksDefault() broken in 2.4.4
Daniel
This commit is contained in:
Daniel Veillard
2001-09-14 10:29:27 +00:00
parent 008186fc7f
commit 166982816e
5 changed files with 26 additions and 11 deletions

View File

@ -1,3 +1,11 @@
Fri Sep 14 12:26:58 CEST 2001 Daniel Veillard <daniel@veillard.com>
* encoding.c entities.c: do not output hexadecimal charrefs
when serializing HTML since some version of Netscape can't
grok it, generate decimal ones.
* result/HTML/doc3.htm: output changed due to previous test
* parserInternals.c: repair xmlKeepBlanksDefault() broken in 2.4.4
Thu Sep 13 13:34:27 CEST 2001 Daniel Veillard <daniel@veillard.com>
* libxml-2.0.pc.in: dohh generated the wrong include path :-(

View File

@ -2264,7 +2264,7 @@ retry:
* and continue the transcoding phase, hoping the error
* did not mangle the encoder state.
*/
sprintf((char *) charref, "&#x%X;", cur);
sprintf((char *) charref, "&#%d;", cur);
xmlBufferShrink(in, len);
xmlBufferAddHead(in, charref, -1);

View File

@ -708,7 +708,10 @@ xmlEncodeEntitiesReentrant(xmlDocPtr doc, const xmlChar *input) {
/*
* We could do multiple things here. Just save as a char ref
*/
snprintf(buf, sizeof(buf), "&#x%X;", val);
if (html)
snprintf(buf, sizeof(buf), "&#%d;", val);
else
snprintf(buf, sizeof(buf), "&#x%X;", val);
buf[sizeof(buf) - 1] = 0;
ptr = buf;
while (*ptr != 0) *out++ = *ptr++;

View File

@ -46,6 +46,7 @@
#include <libxml/valid.h>
#include <libxml/xmlIO.h>
#include <libxml/uri.h>
#include <libxml/SAX.h>
#ifdef LIBXML_CATALOG_ENABLED
#include <libxml/catalog.h>
#endif
@ -2259,6 +2260,9 @@ xmlInitParserCtxt(xmlParserCtxtPtr ctxt)
ctxt->pedantic = xmlPedanticParserDefaultValue;
ctxt->linenumbers = xmlLineNumbersDefaultValue;
ctxt->keepBlanks = xmlKeepBlanksDefaultValue;
if (ctxt->keepBlanks == 0)
sax->ignorableWhitespace = ignorableWhitespace;
ctxt->vctxt.userData = ctxt;
if (ctxt->validate) {
ctxt->vctxt.error = xmlParserValidityError;

View File

@ -104,11 +104,11 @@ eval("page" + id + " = window.open(URL, '" + id + "', 'toolbars=0, scrollbars=0,
<br><!--<hr noshade width=100%>--><b><u><font color="#003366" face="Verdana, Arial" size="2">Chat with
ABIT</font></u></b><br><font color="#0066cc" face="Arial" size="1"><small>Posted by <a class="nav" href="mailto:Holodeck@bp6.com">Holodeck2</a> @ 8:09PM
PDT</small><EFBFBD> <a href="http://bp6.gamesquad.net/news/965012956,78924,.html"><img border="0" src="doc3_files/comments.gif">0 comments</a>
<20>|<7C><a href="http://bp6.gamesquad.net/#news_top">top</a></font><br><font color="black" face="Arial" size="2">I&#x2019;m slacking a little. All game no
<20>|<7C><a href="http://bp6.gamesquad.net/#news_top">top</a></font><br><font color="black" face="Arial" size="2">I&#8217;m slacking a little. All game no
work makes Holodeck2 a happy boy :-)<br><br>Wallpaper update: I got
off my lazy ass and redid the 1280x1024 wall paper, now it has the 2
celerons.<br><br><b><a href="http://fullon3d.com/chat/abit/" target="3d">Fullon3d had a live chat with that Eric guy from Abit.
</a></b>Submitted by: MJS<br><br>Here&#x2019;s a little clip:<br>[Falcon]
</a></b>Submitted by: MJS<br><br>Here&#8217;s a little clip:<br>[Falcon]
BP6-2??<br>[EricBoeing] We already have a micro ATX dual flip-chip
board<br>[EricBoeing] but it's OEM only<br>[EricBoeing] the full ATX
version should be out Septemberish<br></font><br><br><a name="newsitem964766837,26344,"></a><table bgcolor="#003399" width="100%"><tbody><tr><td><font color="#ffffff" face="Verdana,arial" size="2"><b>Thursday,
@ -165,7 +165,7 @@ eval("page" + id + " = window.open(URL, '" + id + "', 'toolbars=0, scrollbars=0,
on a small chip (CPU, GPU, CHIPSET, etc)<br><br><img height="173" src="doc3_files/voodooside2.jpg" width="230"><br>My overclocked
Voodoo3 2000 with a BIG mofo heatsink on top.<br>Peltier and
watercooling next up :-)<br>(if you pry off the heatsink you void
the warranty )<br><br>it was originally posted on <a href="http://www.hardocp.com/">[H]ardOCP </a><br>I&#x2019;m not only a
the warranty )<br><br>it was originally posted on <a href="http://www.hardocp.com/">[H]ardOCP </a><br>I&#8217;m not only a
BP6er but also a [H]ardOCPer<br></font><br><br><a name="newsitem964644047,60218,"></a><b><u><font color="#003366" face="Verdana, Arial" size="2">WiLd CaSe!!</font></u></b><br><font color="#0066cc" face="Arial" size="1"><small>Posted by <a class="nav" href="mailto:Holodeck@bp6.com">Holodeck2</a> @ 1:40PM
PDT</small><EFBFBD> <a href="http://bp6.gamesquad.net/news/964644047,60218,.html"><img border="0" src="doc3_files/comments.gif">8 comments</a>
<20>|<7C><a href="http://bp6.gamesquad.net/#news_top">top</a></font><br><font color="black" face="Arial" size="2">Now this person really knows how to
@ -188,9 +188,9 @@ eval("page" + id + " = window.open(URL, '" + id + "', 'toolbars=0, scrollbars=0,
EVERYONE!!!</font></u></b><br><font color="#0066cc" face="Arial" size="1"><small>Posted by <a class="nav" href="mailto:Holodeck@bp6.com">Holodeck2</a> @ 10:03PM
PDT</small><EFBFBD> <br><font color="black" face="Arial" size="2">Hello
everyone, Woohoo!! I'm on!!<br>Who is this Holodeck2 person
anyways?!?! Read on :-)<br>I&#x2019;m a regular on the bp6 messageboard,
trying to help people out with their problems.<br>I&#x2019;m the
self-proclaimed bp6 cooling expert, If you have a cooling idea, I&#x2019;ve
anyways?!?! Read on :-)<br>I&#8217;m a regular on the bp6 messageboard,
trying to help people out with their problems.<br>I&#8217;m the
self-proclaimed bp6 cooling expert, If you have a cooling idea, I&#8217;ve
probably already done it and can offer some incite.<br>My computer
is always on so you can contact me whenever... problem is, I'm not
always in front of it. I'll try to update this page and keep
@ -200,9 +200,9 @@ eval("page" + id + " = window.open(URL, '" + id + "', 'toolbars=0, scrollbars=0,
will be answered in 24 hours or less, I guarantee it.)<br>When you
write me an e-mail please put in the subject line &quot;BP6&quot; then the
rest of your subject so my e-mail program can sort it, thanks<br><a href="http://www.aol.com/aim">AIM: </a>Holodeck2 (instant response
if I&#x2019;m in front of my comp and not trying to frag someone)<br><a href="http://www.icq.com/download">ICQ: </a>82640218 (rarely
on)<br><br>P.S. If someone named &#x201C;Digital Vortex&#x201D; on either Quake 3
or 2 frags you, it&#x2019;s probably me. ;-)<br></font><br><br><a name="newsitem964429577,13375,"></a><table bgcolor="#003399" width="100%"><tbody><tr><td><font color="#ffffff" face="Verdana,arial" size="2"><b>Monday,
if I&#8217;m in front of my comp and not trying to frag someone)<br><a href="http://www.icq.com/download">ICQ: </a>82640218 (rarely
on)<br><br>P.S. If someone named &#8220;Digital Vortex&#8221; on either Quake 3
or 2 frags you, it&#8217;s probably me. ;-)<br></font><br><br><a name="newsitem964429577,13375,"></a><table bgcolor="#003399" width="100%"><tbody><tr><td><font color="#ffffff" face="Verdana,arial" size="2"><b>Monday,
July 24, 2000</b></font></td></tr></tbody></table>
<br><!--<hr noshade width=100%>--><b><u><font color="#003366" face="Verdana, Arial" size="2">BP6 Q3 server up and
running..</font></u></b><br><font color="#0066cc" face="Arial" size="1"><small>Posted by <a class="nav" href="mailto:tim@bp6.com">tim</a> @ 2:06AM PDT</small><EFBFBD> <a href="http://bp6.gamesquad.net/news/964429577,13375,.html"><img border="0" src="doc3_files/comments.gif">3 comments</a>