aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org>2018-11-02 12:47:51 +0200
committerSergey Poznyakoff <gray@gnu.org>2018-11-03 18:27:57 +0200
commitd8b9854a76d69e99bbbddd285a0e0d7727a62e4f (patch)
tree07530d46481f2c70a0b5e6186e1cb6480ad1f8e0
parent62ac2fa1db13e2c688c6112cd6cb7682a232f16a (diff)
downloadmailfromd-d8b9854a76d69e99bbbddd285a0e0d7727a62e4f.tar.gz
mailfromd-d8b9854a76d69e99bbbddd285a0e0d7727a62e4f.tar.bz2
Revise preprocessor macros for builtin functions.
* doc/mailfromd.texi: Minor change. * src/builtin/Makefile.am (builtin.h): Depend pn init.m4 (.bi.c): Don't eliminate first #line * src/builtin/snarf.m4 (MF_BUILTIN_MODULE): New macro. (MF_INIT): Rewrite. Revise comments. * src/builtin/init.m4 (MF_BUILTIN_MODULE): New macro. (MF_INIT): Remove. * src/builtin/body.bi: Use MF_BUILTIN_MODULE statement. * src/builtin/burst.bi: Likewise. * src/builtin/callout.bi: Likewise. * src/builtin/ctype.bi: Likewise. * src/builtin/curhdr.bi: Likewise. * src/builtin/db.bi: Likewise. * src/builtin/debug.bi: Likewise. * src/builtin/dns.bi: Likewise. * src/builtin/dspam.bi: Likewise. * src/builtin/email.bi: Likewise. * src/builtin/from.bi: Likewise. * src/builtin/geoip.bi: Likewise. * src/builtin/gethostname.bi: Likewise. * src/builtin/getopt.bi: Likewise. * src/builtin/getpw.bi: Likewise. * src/builtin/gettext.bi: Likewise. * src/builtin/header.bi: Likewise. * src/builtin/io.bi: Likewise. * src/builtin/ipaddr.bi: Likewise. * src/builtin/macro.bi: Likewise. * src/builtin/mail.bi: Likewise. * src/builtin/mbox.bi: Likewise. * src/builtin/mmq.bi: Likewise. * src/builtin/msg.bi: Likewise. * src/builtin/other.bi: Likewise. * src/builtin/prereq.bi: Likewise. * src/builtin/progress.bi: Likewise. * src/builtin/qrnt.bi: Likewise. * src/builtin/rate.bi: Likewise. * src/builtin/rcpt.bi: Likewise. * src/builtin/sa.bi: Likewise. * src/builtin/sieve.bi: Likewise. * src/builtin/spf.bi: Likewise. * src/builtin/sprintf.bi: Likewise. * src/builtin/string.bi: Likewise. * src/builtin/syslog.bi: Likewise. * src/builtin/system.bi: Likewise. * src/builtin/vars.bi: Likewise.
-rw-r--r--doc/mailfromd.texi4
-rw-r--r--src/builtin/Makefile.am6
-rw-r--r--src/builtin/body.bi3
-rw-r--r--src/builtin/builtin.def2
-rw-r--r--src/builtin/burst.bi2
-rw-r--r--src/builtin/callout.bi1
-rw-r--r--src/builtin/ctype.bi2
-rw-r--r--src/builtin/curhdr.bi2
-rw-r--r--src/builtin/db.bi3
-rw-r--r--src/builtin/debug.bi3
-rw-r--r--src/builtin/dns.bi3
-rw-r--r--src/builtin/dspam.bi2
-rw-r--r--src/builtin/email.bi2
-rw-r--r--src/builtin/from.bi3
-rw-r--r--src/builtin/geoip.bi3
-rw-r--r--src/builtin/gethostname.bi5
-rw-r--r--src/builtin/getopt.bi2
-rw-r--r--src/builtin/getpw.bi4
-rw-r--r--src/builtin/gettext.bi5
-rw-r--r--src/builtin/header.bi3
-rw-r--r--src/builtin/init.m419
-rw-r--r--src/builtin/io.bi2
-rw-r--r--src/builtin/ipaddr.bi5
-rw-r--r--src/builtin/macro.bi3
-rw-r--r--src/builtin/mail.bi3
-rw-r--r--src/builtin/mbox.bi2
-rw-r--r--src/builtin/mmq.bi3
-rw-r--r--src/builtin/msg.bi2
-rw-r--r--src/builtin/other.bi3
-rw-r--r--src/builtin/prereq.bi3
-rw-r--r--src/builtin/progress.bi3
-rw-r--r--src/builtin/qrnt.bi3
-rw-r--r--src/builtin/rate.bi3
-rw-r--r--src/builtin/rcpt.bi3
-rw-r--r--src/builtin/sa.bi4
-rw-r--r--src/builtin/sieve.bi3
-rw-r--r--src/builtin/snarf.m4550
-rw-r--r--src/builtin/spf.bi3
-rw-r--r--src/builtin/sprintf.bi3
-rw-r--r--src/builtin/string.bi3
-rw-r--r--src/builtin/syslog.bi3
-rw-r--r--src/builtin/system.bi3
-rw-r--r--src/builtin/vars.bi3
43 files changed, 467 insertions, 225 deletions
diff --git a/doc/mailfromd.texi b/doc/mailfromd.texi
index 6230d35c..704cd030 100644
--- a/doc/mailfromd.texi
+++ b/doc/mailfromd.texi
@@ -3328,11 +3328,11 @@ A special language construct is provided to supply the second
argument (@var{argv}) to @code{getopt} and similar functions:
@smallexample
-vaptr(@var{arg})
+vaptr(@var{param})
@end smallexample
@noindent
-where @var{argv} is a positional parameter, from which to start the
+where @var{param} is a positional parameter, from which to start the
array of @var{argv}. For example:
@smallexample
diff --git a/src/builtin/Makefile.am b/src/builtin/Makefile.am
index 2e397f11..7d5db661 100644
--- a/src/builtin/Makefile.am
+++ b/src/builtin/Makefile.am
@@ -79,7 +79,7 @@ AM_CPPFLAGS = \
-I$(top_srcdir)\
$(DSPAM_CFLAGS)
-builtin.h: Makefile.am builtin.def
+builtin.h: Makefile.am builtin.def init.m4
$(BI_FILES:.bi=.c): snarf.m4 init.m4
@@ -88,9 +88,7 @@ SUFFIXES = .bi .c .def .h .mfi .mf
M4=m4
.bi.c:
- $(AM_V_GEN)$(M4) --prefix -s -DSOURCE="$<" $(top_srcdir)/src/builtin/snarf.m4 $< > $@-t && \
- sed '1{/#line/d;}' $@-t > $@ && \
- rm $@-t
+ $(AM_V_GEN)$(M4) --prefix -s -DSOURCE="$<" $(top_srcdir)/src/builtin/snarf.m4 $< > $@
.def.h:
$(AM_V_GEN) $(M4) --prefix $(top_srcdir)/src/builtin/init.m4 $(BI_FILES) $< > $@
diff --git a/src/builtin/body.bi b/src/builtin/body.bi
index ab6611ff..8626f122 100644
--- a/src/builtin/body.bi
+++ b/src/builtin/body.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include "msg.h"
MF_STATE(body)
@@ -66,4 +68,3 @@ MF_DEFUN(replbody_fd, VOID, NUMBER fd)
}
END
-MF_INIT
diff --git a/src/builtin/builtin.def b/src/builtin/builtin.def
index ea1b39a4..3595df79 100644
--- a/src/builtin/builtin.def
+++ b/src/builtin/builtin.def
@@ -1,4 +1,4 @@
-/* This file is part of Mailfromd.
+/* This file is part of Mailfromd. -*- C -*-
Copyright (C) 2010-2018 Sergey Poznyakoff
This program is free software; you can redistribute it and/or modify
diff --git a/src/builtin/burst.bi b/src/builtin/burst.bi
index 34971f3b..ae0bb83c 100644
--- a/src/builtin/burst.bi
+++ b/src/builtin/burst.bi
@@ -16,6 +16,8 @@
/* Functions for converting RFC-934 digests into MIME messages.
Largely inspired by MU's mh/burst.c */
+
+MF_BUILTIN_MODULE
#include <mflib/status.h>
#include "msg.h"
#include "global.h"
diff --git a/src/builtin/callout.bi b/src/builtin/callout.bi
index 3c3f1586..24f9400f 100644
--- a/src/builtin/callout.bi
+++ b/src/builtin/callout.bi
@@ -15,6 +15,7 @@
along with this program. If not, see <http://www.gnu.org/licenses/>. */
/* Run-time support for callout functions */
+MF_BUILTIN_MODULE
#include "filenames.h"
#include "callout.h"
diff --git a/src/builtin/ctype.bi b/src/builtin/ctype.bi
index e452e25d..faa3e703 100644
--- a/src/builtin/ctype.bi
+++ b/src/builtin/ctype.bi
@@ -14,6 +14,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
MF_VAR(ctype_mismatch, NUMBER);
m4_define([<MF_DEFUN_CTYPE>],[<
@@ -44,4 +45,3 @@ MF_DEFUN_CTYPE(isspace)
MF_DEFUN_CTYPE(isupper)
MF_DEFUN_CTYPE(isxdigit)
-MF_INIT
diff --git a/src/builtin/curhdr.bi b/src/builtin/curhdr.bi
index e7dc4606..14430d6c 100644
--- a/src/builtin/curhdr.bi
+++ b/src/builtin/curhdr.bi
@@ -14,6 +14,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
#include "msg.h"
/* number current_header_count([string name]) */
@@ -148,4 +149,3 @@ MF_DEFUN(current_header, STRING, STRING name, OPTIONAL, NUMBER index)
}
END
-MF_INIT
diff --git a/src/builtin/db.bi b/src/builtin/db.bi
index 7186e3c7..8dea160e 100644
--- a/src/builtin/db.bi
+++ b/src/builtin/db.bi
@@ -14,6 +14,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
#define DEFAULT_DB_MODE 0640
#include <fnmatch.h>
@@ -967,5 +968,3 @@ MF_DEFUN(db_expire_interval, NUMBER, STRING fmtid)
}
END
-MF_INIT
-
diff --git a/src/builtin/debug.bi b/src/builtin/debug.bi
index e2307946..f9a49c69 100644
--- a/src/builtin/debug.bi
+++ b/src/builtin/debug.bi
@@ -14,6 +14,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
#include "mflib/_register.h"
#include "srvcfg.h"
@@ -132,4 +133,4 @@ MF_INIT([<
bi_debug, 0, dtype_unspecified, 1, 0, 0,
dtype_string);
>])
-
+
diff --git a/src/builtin/dns.bi b/src/builtin/dns.bi
index 6a98dfd5..b417a8c1 100644
--- a/src/builtin/dns.bi
+++ b/src/builtin/dns.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include <sys/socket.h>
#include <netinet/in.h>
#include <netdb.h>
@@ -277,4 +279,3 @@ MF_DEFUN(ptr_validate, NUMBER, STRING s)
}
END
-MF_INIT
diff --git a/src/builtin/dspam.bi b/src/builtin/dspam.bi
index cc4b7d23..d1ab7e71 100644
--- a/src/builtin/dspam.bi
+++ b/src/builtin/dspam.bi
@@ -14,6 +14,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
MF_COND(WITH_DSPAM)
#include "srvcfg.h"
@@ -529,4 +530,3 @@ MF_DEFUN(dspam, NUMBER, NUMBER nmsg, NUMBER mode_flags, OPTIONAL, NUMBER class_s
}
END
-MF_INIT
diff --git a/src/builtin/email.bi b/src/builtin/email.bi
index 2d90abcc..a396f24d 100644
--- a/src/builtin/email.bi
+++ b/src/builtin/email.bi
@@ -14,6 +14,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
#include "mflib/email.h"
MF_DEFUN(domainpart, STRING, STRING str)
@@ -77,4 +78,3 @@ MF_DEFUN(email_map, NUMBER, STRING str)
}
END
-MF_INIT
diff --git a/src/builtin/from.bi b/src/builtin/from.bi
index 57201520..73a84cd5 100644
--- a/src/builtin/from.bi
+++ b/src/builtin/from.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
MF_DEFUN(set_from, VOID, STRING addr, OPTIONAL, STRING args)
{
struct mu_locus_range locus;
@@ -29,4 +31,3 @@ MF_DEFUN(set_from, VOID, STRING addr, OPTIONAL, STRING args)
}
END
-MF_INIT
diff --git a/src/builtin/geoip.bi b/src/builtin/geoip.bi
index b2dcad93..c40a1845 100644
--- a/src/builtin/geoip.bi
+++ b/src/builtin/geoip.bi
@@ -14,6 +14,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
MF_COND(WITH_GEOIP)
#include <GeoIP.h>
@@ -55,5 +56,3 @@ MF_DEFUN(geoip_country_code_by_name, STRING, STRING name,
}
END
-MF_INIT
-
diff --git a/src/builtin/gethostname.bi b/src/builtin/gethostname.bi
index 3d616683..9914a574 100644
--- a/src/builtin/gethostname.bi
+++ b/src/builtin/gethostname.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#ifndef ENAMETOOLONG
# define ENAMETOOLONG 0
#endif
@@ -134,5 +136,4 @@ MF_DEFUN(getdomainname, STRING)
MF_RETURN_OBSTACK();
}
END
-
-MF_INIT
+
diff --git a/src/builtin/getopt.bi b/src/builtin/getopt.bi
index 3303052e..e50f3eb0 100644
--- a/src/builtin/getopt.bi
+++ b/src/builtin/getopt.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include <unistd.h>
#include <stdlib.h>
#include <getopt.h>
diff --git a/src/builtin/getpw.bi b/src/builtin/getpw.bi
index a148a713..7e127198 100644
--- a/src/builtin/getpw.bi
+++ b/src/builtin/getpw.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
static void
return_passwd(eval_environ_t env, struct passwd *pw)
{
@@ -75,5 +77,3 @@ MF_DEFUN(getpwuid, STRING, NUMBER uid)
}
END
-
-MF_INIT
diff --git a/src/builtin/gettext.bi b/src/builtin/gettext.bi
index 070c294e..329feae9 100644
--- a/src/builtin/gettext.bi
+++ b/src/builtin/gettext.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
MF_DEFUN(bindtextdomain, STRING, STRING domain, STRING dirname)
{
const char *s = bindtextdomain(domain[0] ? domain : NULL, dirname);
@@ -37,6 +39,3 @@ MF_DEFUN(dngettext, STRING, STRING domain,
}
END
-MF_INIT
-
-
diff --git a/src/builtin/header.bi b/src/builtin/header.bi
index 2922157e..e46183df 100644
--- a/src/builtin/header.bi
+++ b/src/builtin/header.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
MF_DEFUN(header_add, VOID, STRING name, STRING value, OPTIONAL, NUMBER idx)
{
struct mu_locus_range locus;
@@ -117,4 +119,3 @@ MF_DEFUN(header_replace_nth, VOID, NUMBER idx, STRING name, STRING value)
}
END
-MF_INIT
diff --git a/src/builtin/init.m4 b/src/builtin/init.m4
index 64cdd9d7..73168b58 100644
--- a/src/builtin/init.m4
+++ b/src/builtin/init.m4
@@ -18,12 +18,6 @@ m4_divert(-1)
m4_changequote([<,>])
m4_changecom(/*,*/)
-m4_define([<MF_MODULE_NAME>],[<m4_dnl
-m4_patsubst(m4___file__,\(.*/\)?\(.*\)\.bi,\2)>])
-
-m4_define([<MF_MODULE_IDX>],[<m4_dnl
-[<BUILTIN_IDX_>]MF_MODULE_NAME()>])
-
m4_define([<__MODNO__>],0)
m4_define([<MF_BEGIN_OUTPUT>],[<m4_dnl
@@ -51,13 +45,16 @@ m4_undivert(3)
#define BUILTIN_IDX_MAX (sizeof(builtin_module)/sizeof(builtin_module[0])-1)
>])
-m4_define([<MF_INIT>],[<m4_dnl
-m4_pushdef([<MODNAME>],MF_MODULE_NAME())
+m4_define([<MF_BUILTIN_MODULE>],
+[<m4_pushdef([<MF_MODULE_NAME>],
+m4_ifelse([<$1>],,[<m4_dnl
+m4_patsubst(m4___file__,\(.*/\)?\(.*\)\.bi,\2)>],[<$1>]))
+m4_pushdef([<MF_MODULE_IDX>],[<[<BUILTIN_IDX_>]MF_MODULE_NAME()>])
m4_define([<__MODNO__>],m4_incr(__MODNO__))
m4_divert(1)m4_dnl
#define MF_MODULE_IDX (__MODNO__)
m4_divert(2)m4_dnl
-extern void MODNAME[<>]_init_builtin(void);
+extern void MF_MODULE_NAME[<>]_init_builtin(void);
m4_divert(3)m4_dnl
- { "MODNAME", MODNAME[<>]_init_builtin, 0 },
-m4_divert(-1)m4_dnl>])
+ { "MF_MODULE_NAME", MF_MODULE_NAME[<>]_init_builtin, 0 },
+m4_divert(-1)>])
diff --git a/src/builtin/io.bi b/src/builtin/io.bi
index 2ca80e2a..d1512ad8 100644
--- a/src/builtin/io.bi
+++ b/src/builtin/io.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include <mflib/status.h>
#include <sys/types.h>
#include <sys/stat.h>
diff --git a/src/builtin/ipaddr.bi b/src/builtin/ipaddr.bi
index 9ede3b4d..a586342c 100644
--- a/src/builtin/ipaddr.bi
+++ b/src/builtin/ipaddr.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
@@ -97,6 +99,3 @@ MF_DEFUN(netmask_to_len, NUMBER, NUMBER x)
}
END
-MF_INIT
-
-
diff --git a/src/builtin/macro.bi b/src/builtin/macro.bi
index 757bbf8f..2d41ff71 100644
--- a/src/builtin/macro.bi
+++ b/src/builtin/macro.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
/* #pragma miltermacros <handler> <name> [name...] */
MF_PRAGMA(miltermacros, 3, 0)
{
@@ -46,4 +48,3 @@ MF_DEFUN(macro_defined, NUMBER, STRING name)
}
END
-MF_INIT
diff --git a/src/builtin/mail.bi b/src/builtin/mail.bi
index dc7ea34b..edf21b3b 100644
--- a/src/builtin/mail.bi
+++ b/src/builtin/mail.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include "msg.h"
static int
@@ -335,4 +337,3 @@ MF_DEFUN(send_dsn, VOID, STRING to,
}
END
-MF_INIT
diff --git a/src/builtin/mbox.bi b/src/builtin/mbox.bi
index a0226ce2..df4f3ec2 100644
--- a/src/builtin/mbox.bi
+++ b/src/builtin/mbox.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include "msg.h"
#include "global.h"
diff --git a/src/builtin/mmq.bi b/src/builtin/mmq.bi
index c9c24bc5..5ad0e32c 100644
--- a/src/builtin/mmq.bi
+++ b/src/builtin/mmq.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
/* Clear the list of message modification requests. This function undoes
the effect of the following functions, if they had been called
previously: rcpt_add, rcpt_delete, header_add, header_insert,
@@ -25,4 +27,3 @@ MF_DEFUN(mmq_purge, VOID)
}
END
-MF_INIT
diff --git a/src/builtin/msg.bi b/src/builtin/msg.bi
index faaa7bf5..46e63cd2 100644
--- a/src/builtin/msg.bi
+++ b/src/builtin/msg.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include "msg.h"
#include "global.h"
diff --git a/src/builtin/other.bi b/src/builtin/other.bi
index 673f4515..5063885e 100644
--- a/src/builtin/other.bi
+++ b/src/builtin/other.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include "mflib/_register.h"
static int
@@ -69,4 +71,3 @@ MF_DEFUN(interval, NUMBER, STRING str)
}
END
-MF_INIT
diff --git a/src/builtin/prereq.bi b/src/builtin/prereq.bi
index d51c0e39..9d92b0a6 100644
--- a/src/builtin/prereq.bi
+++ b/src/builtin/prereq.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
/* #pragma prereq <version> */
MF_PRAGMA(prereq, 1, 0)
{
@@ -42,4 +44,3 @@ MF_DEFUN(vercmp, NUMBER, STRING a, STRING b)
}
END
-MF_INIT
diff --git a/src/builtin/progress.bi b/src/builtin/progress.bi
index 00bb1a5a..484b8bb4 100644
--- a/src/builtin/progress.bi
+++ b/src/builtin/progress.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
MF_STATE(eom)
MF_DEFUN(progress, VOID)
{
@@ -29,4 +31,3 @@ MF_DEFUN(progress, VOID)
}
END
-MF_INIT
diff --git a/src/builtin/qrnt.bi b/src/builtin/qrnt.bi
index 85a961bd..74fc8331 100644
--- a/src/builtin/qrnt.bi
+++ b/src/builtin/qrnt.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
MF_DEFUN(quarantine, VOID, STRING reason)
{
struct mu_locus_range locus;
@@ -29,4 +31,3 @@ MF_DEFUN(quarantine, VOID, STRING reason)
}
END
-MF_INIT
diff --git a/src/builtin/rate.bi b/src/builtin/rate.bi
index bfbc8260..adf7a492 100644
--- a/src/builtin/rate.bi
+++ b/src/builtin/rate.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
MF_DEFUN(rate, NUMBER, STRING key, NUMBER interval, OPTIONAL, NUMBER mincnt,
NUMBER threshold)
{
@@ -43,4 +45,3 @@ MF_DEFUN(tbf_rate, NUMBER, STRING key, NUMBER cost,
}
END
-MF_INIT
diff --git a/src/builtin/rcpt.bi b/src/builtin/rcpt.bi
index bbd63fcc..9f053f77 100644
--- a/src/builtin/rcpt.bi
+++ b/src/builtin/rcpt.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
MF_DEFUN(rcpt_add, VOID, STRING addr)
{
struct mu_locus_range locus;
@@ -44,4 +46,3 @@ MF_DEFUN(rcpt_delete, VOID, STRING addr)
}
END
-MF_INIT
diff --git a/src/builtin/sa.bi b/src/builtin/sa.bi
index ca4c6165..fd3fa0b7 100644
--- a/src/builtin/sa.bi
+++ b/src/builtin/sa.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include <unistd.h>
#include <stdlib.h>
#include <sys/types.h>
@@ -588,5 +590,3 @@ MF_DEFUN(clamav, NUMBER, NUMBER nmsg, STRING urlstr)
}
END
-MF_INIT
-
diff --git a/src/builtin/sieve.bi b/src/builtin/sieve.bi
index ba23f4d4..0e594a37 100644
--- a/src/builtin/sieve.bi
+++ b/src/builtin/sieve.bi
@@ -14,6 +14,8 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+MF_BUILTIN_MODULE
+
#include <mailutils/mailutils.h>
#include <mflib/sieve.h>
#include "msg.h"
@@ -147,4 +149,3 @@ MF_DEFUN(sieve, NUMBER, NUMBER nmsg, STRING script, OPTIONAL, NUMBER flags,
}
END
-MF_INIT
diff --git a/src/builtin/snarf.m4 b/src/builtin/snarf.m4
index bafd12c4..2a32b02a 100644
--- a/src/builtin/snarf.m4
+++ b/src/builtin/snarf.m4
@@ -27,7 +27,7 @@ m4_changecom(/*,*/)
m4_define([<__mf_dataseg>])
/* The MF_DSEXP attribute indicates that the MF_DEFUN that follows it
- * can cause dataseg expansion
+ * can cause dataseg expansion.
*/
m4_define([<MF_DSEXP>],[<m4_define([<__mf_dataseg>],[<MFL_DATASEG>])>])
@@ -37,7 +37,7 @@ m4_define([<MF_DSEXP>],[<m4_define([<__mf_dataseg>],[<MFL_DATASEG>])>])
* The intent is to warn the programmer that the function in question can
* result in dataseg being expanded. The warning is suppressed by MF_DSEXP
* attribute (for MF_DEFUNs) or by the use of MF_DSEXP_SUPPRESS macro (for
- * C functions).
+ * C functions).
*/
m4_define([<__MF_DSEXP_REQ>],[<m4_dnl
m4_ifelse(__mf_dataseg,[