two small patches

Graham Wilson bob at decoy.wox.org
Tue Dec 31 07:33:58 CET 2002


here are two small patches for bogofilter.

this one fixes a bug that prevented compiling if both the graham and
robinson methods were disabled:

Index: config.c
===================================================================
RCS file: /cvsroot/bogofilter/bogofilter/config.c,v
retrieving revision 1.90
diff -u -r1.90 config.c
--- config.c	27 Dec 2002 04:57:27 -0000	1.90
+++ config.c	31 Dec 2002 06:19:32 -0000
@@ -96,10 +96,14 @@
 };
 
 /* define default */
-#ifdef ENABLE_ROBINSON_METHOD
+#if defined (ENABLE_ROBINSON_METHOD)
 #define AL_DEFAULT AL_ROBINSON
-#else
+#elif defined (ENABLE_GRAHAM_METHOD)
 #define AL_DEFAULT AL_GRAHAM
+#elif defined (ENABLE_ROBINSON_FISHER)
+#define AL_DEFAULT AL_FISHER
+#else
+#error No algorithms compiled in. See configure --help.
 #endif
 
 double	spam_cutoff = 0.0;			/* set during method initialization */

this one fixes the build process so that it doesn't call xmllint. newer
versions (>= 0.0.11) call xmllint by default, thus resulting in xmllint
being called twice.

Index: Makefile.am
===================================================================
RCS file: /cvsroot/bogofilter/bogofilter/Makefile.am,v
retrieving revision 1.101
diff -u -r1.101 Makefile.am
--- Makefile.am	27 Dec 2002 22:23:09 -0000	1.101
+++ Makefile.am	31 Dec 2002 06:25:00 -0000
@@ -115,7 +115,7 @@
 	xmlto html-nochunks $<
 
 .xml.1:
-	{ xmllint --noout --postvalid $< && xmlto man $< ; } || { rm -f $@ ; exit 1 ; }
+	xmlto man $< || { rm -f $@ ; exit 1 ; }
 
 .PHONY: rpm cvs-check
 
-- 
gram




More information about the bogofilter-dev mailing list