Fix for src/parse.c for "<!-- " comments in included header

From: David D. Kilzer <ddkilzer_at_madison.dseg.ti.com_at_hypermail-project.org>
Date: Tue, 11 Aug 1998 18:28:22 -0500
Message-Id: <199808112328.SAA04922_at_elbonia.dseg.ti.com>


I just set up an installation of Hypermail to use HTML header files for messages. One of the header files included an HTML comment at the beginning of the line, which threw off loadoldheaders() in src/parse.c.

The patch below "fixes" this by checking for more than just "<!-- " before it starts parsing for the previous header information.

And before someone says, "I've found this already, sent the patch to Kevin, and it should be included in 2.0b3", when *is* 2.0b3 supposed to be out? :^)

Thanks!

Dave

--
David D. Kilzer
Software Designer
Raytheon Systems Company
ddkilzer_at_ti.com


--- hypermail-20b2/src/parse.c.cln	Tue Aug 11 16:50:50 1998
+++ hypermail-20b2/src/parse.c	Tue Aug 11 17:53:18 1998
_at_@ -1453,7 +1453,7 @@
     while ((fp = fopen(filename, "r")) != NULL) {
 
         /* skip all lines before the first <!-- */
-        while ( fgets(line, MAXLINE, fp), strncmp(line, "<!-- ", 5) );
+        while ( fgets(line, MAXLINE, fp), strncasecmp(line, "<!-- received", 13) );
 
         strcpymax(fromdate, (char *) getvalue(line), DATESTRLEN);
 
Received on Wed 12 Aug 1998 01:31:15 AM GMT

This archive was generated by hypermail 2.3.0 : Sat 13 Mar 2010 03:46:11 AM GMT GMT