aboutsummaryrefslogtreecommitdiff
path: root/mail/milter-regex
diff options
context:
space:
mode:
authorDirk Meyer <dinoex@FreeBSD.org>2007-02-17 09:09:43 +0000
committerDirk Meyer <dinoex@FreeBSD.org>2007-02-17 09:09:43 +0000
commit7d8819ea3d7a2519c47c483a84482bcd4ea12cc6 (patch)
treed19d873f17745ce78f1f891845541d475c22eec5 /mail/milter-regex
parent1034310476481a271c235d465ebf949c032d43f0 (diff)
downloadports-7d8819ea3d7a2519c47c483a84482bcd4ea12cc6.tar.gz
ports-7d8819ea3d7a2519c47c483a84482bcd4ea12cc6.zip
- add flag -quiet
PR: 106602 Submitted by: Denis Eremenko
Notes
Notes: svn path=/head/; revision=185358
Diffstat (limited to 'mail/milter-regex')
-rw-r--r--mail/milter-regex/Makefile1
-rw-r--r--mail/milter-regex/files/patch-quiet51
2 files changed, 52 insertions, 0 deletions
diff --git a/mail/milter-regex/Makefile b/mail/milter-regex/Makefile
index c5bb664e7101..e05d481b787e 100644
--- a/mail/milter-regex/Makefile
+++ b/mail/milter-regex/Makefile
@@ -8,6 +8,7 @@
PORTNAME= milter-regex
PORTVERSION= 1.6
+PORTREVISION= 1
CATEGORIES= mail
MASTER_SITES= http://www.benzedrine.cx/
diff --git a/mail/milter-regex/files/patch-quiet b/mail/milter-regex/files/patch-quiet
new file mode 100644
index 000000000000..5b09559ebea6
--- /dev/null
+++ b/mail/milter-regex/files/patch-quiet
@@ -0,0 +1,51 @@
+--- milter-regex.8.orig Thu Dec 21 17:15:05 2006
++++ milter-regex.8 Thu Dec 21 17:22:46 2006
+@@ -52,6 +52,8 @@
+ .It Fl d
+ Don't detach from controlling terminal and produce verbose debug
+ output on stdout.
++.It Fl q
++Don't send to syslog messages with priority higher than LOG_NOTICE.
+ .It Fl c Ar config
+ Use the specified configuration file instead of the default,
+ /etc/milter-regex.conf.
+--- milter-regex.c.orig Thu Dec 21 17:13:26 2006
++++ milter-regex.c Thu Dec 21 17:23:28 2006
+@@ -57,6 +57,7 @@
+
+ static const char *rule_file_name = "/etc/milter-regex.conf";
+ static int debug = 0;
++static int quiet = 0;
+
+ struct context {
+ struct ruleset *rs;
+@@ -520,6 +521,9 @@
+ va_list ap;
+ char msg[8192];
+
++ if (LOG_PRI(priority) > LOG_INFO && quiet)
++ return;
++
+ va_start(ap, fmt);
+ if (context != NULL)
+ snprintf(msg, sizeof(msg), "%s: ", context->host_addr);
+@@ -563,13 +567,16 @@
+ tzset();
+ openlog("milter-regex", LOG_PID | LOG_NDELAY, LOG_DAEMON);
+
+- while ((ch = getopt(argc, argv, "c:dp:u:")) != -1) {
++ while ((ch = getopt(argc, argv, "c:dqp:u:")) != -1) {
+ switch (ch) {
+ case 'c':
+ rule_file_name = optarg;
+ break;
+ case 'd':
+ debug = 1;
++ break;
++ case 'q':
++ quiet = 1;
+ break;
+ case 'p':
+ oconn = optarg;
+
+