diff --git a/ChangeLog b/ChangeLog index 655832bb..c9b34868 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Tue Oct 3 11:28:52 CEST 2000 Daniel Veillard + + * HTMLparser.c: Doohhh, attribute name parsing was still case + sensitive ! Fixed this ... + * result/HTML/* : updated the tests results accordingly + Mon Oct 2 23:47:32 CEST 2000 Daniel Veillard * xpath.[ch] debugXML.c testXPath.c: fixed the XPath evaluation diff --git a/HTMLparser.c b/HTMLparser.c index cfd0711a..acb13b43 100644 --- a/HTMLparser.c +++ b/HTMLparser.c @@ -142,10 +142,6 @@ PUSH_AND_POP(extern, xmlChar*, name) #define SKIP_BLANKS htmlSkipBlankChars(ctxt); -#if 0 -#define CUR ((int) (*ctxt->input->cur)) -#define NEXT htmlNextChar(ctxt); -#else /* Inported from XML */ /* #define CUR (ctxt->token ? ctxt->token : (int) (*ctxt->input->cur)) */ @@ -175,7 +171,6 @@ PUSH_AND_POP(extern, xmlChar*, name) #define COPY_BUF(l,b,i,v) \ if (l == 1) b[i++] = (xmlChar) v; \ else i += xmlCopyChar(l,&b[i],v); -#endif /** * htmlCurrentChar: @@ -1858,27 +1853,6 @@ htmlParseName(htmlParserCtxtPtr ctxt) { xmlChar * htmlParseHTMLAttribute(htmlParserCtxtPtr ctxt, const xmlChar stop) { -#if 0 - xmlChar buf[HTML_MAX_NAMELEN]; - int len = 0; - - GROW; - while ((CUR != 0) && (CUR != stop) && (CUR != '>')) { - if ((stop == 0) && (IS_BLANK(CUR))) break; - buf[len++] = CUR; - NEXT; - if (len >= HTML_MAX_NAMELEN) { - fprintf(stderr, - "htmlParseHTMLAttribute: reached HTML_MAX_NAMELEN limit\n"); - while ((!IS_BLANK(CUR)) && (CUR != '<') && - (CUR != '>') && - (CUR != '\'') && (CUR != '"')) - NEXT; - break; - } - } - return(xmlStrndup(buf, len)); -#else xmlChar *buffer = NULL; int buffer_size = 0; xmlChar *out = NULL; @@ -1998,7 +1972,6 @@ htmlParseHTMLAttribute(htmlParserCtxtPtr ctxt, const xmlChar stop) { } *out++ = 0; return(buffer); -#endif } /** @@ -2620,7 +2593,7 @@ htmlParseAttribute(htmlParserCtxtPtr ctxt, xmlChar **value) { xmlChar *name, *val = NULL; *value = NULL; - name = htmlParseName(ctxt); + name = htmlParseHTMLName(ctxt); if (name == NULL) { if ((ctxt->sax != NULL) && (ctxt->sax->error != NULL)) ctxt->sax->error(ctxt->userData, "error parsing attribute name\n"); diff --git a/result/HTML/doc2.htm b/result/HTML/doc2.htm index 07fcc3e2..f0b27a3b 100644 --- a/result/HTML/doc2.htm +++ b/result/HTML/doc2.htm @@ -8,17 +8,19 @@ function NS_NewOpen(url,nam,atr){return(new NS_NullWindow());} window.open=NS_NewOpen; - + + +

-equiv=Content-Type> - - - + + - - + + <body bgcolor="#FFFFFF" text="#000000" link="#000080" vlink="#000080" alink="#000080" topmargin="0" leftmargin="0" marginheight="0" marginwidth="0"><p>This page uses frames, but your browser doesn't support them.</p></body> - + + diff --git a/result/HTML/doc2.htm.err b/result/HTML/doc2.htm.err index bf46ffad..da3f2892 100644 --- a/result/HTML/doc2.htm.err +++ b/result/HTML/doc2.htm.err @@ -1,3 +1,15 @@ ./test/HTML/doc2.htm:10: error: Misplaced DOCTYPE declaration + ^ +./test/HTML/doc2.htm:11: error: htmlParseStartTag: problem parsing attributes + + ^ +./test/HTML/doc2.htm:11: error: Couldn't find end of Start Tag meta + + ^ +./test/HTML/doc2.htm:18: error: Unexpected end tag : head + - + + + +

-equiv=Content-Type>