W3C home > Mailing lists > Public > www-lib@w3.org > April to June 1999

Comment handling

From: Sam Couter <sam@topic.com.au>
Date: Mon, 17 May 1999 14:25:38 +1000
Message-ID: <373F9A42.601BA25D@topic.com.au>
To: www-lib@w3.org
A small patch follows to handle the incorrect but common case of comments
following a structure similar to this:
<!------------------------------------------------
     Here's my comment that I like to make stand out
     with lots of hyphens, even though it's not
     legal HTML.
-------------------------------------------------->

Someone with CVS access may want to check it over, test it, commit it if they
like.

Index: Library/src/SGML.c
===================================================================
RCS file: /sources/public/libwww/Library/src/SGML.c,v
retrieving revision 1.52
diff -u -r1.52 SGML.c
--- SGML.c  1999/04/02 16:10:36 1.52
+++ SGML.c  1999/05/17 04:12:59
@@ -762,6 +762,8 @@
                text = b;
                count = 0;
                context->state = S_text;
+           } else if (c == '-') {
+               context->state = S_com_2a;
            } else
                context->state = S_com;
            break;

Enjoy.
-- 
Sam Couter                                             sam@topic.com.au
Internet Engineer
tSA Consulting
Received on Monday, 17 May 1999 00:25:55 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 23 April 2007 18:18:29 GMT