summaryrefslogtreecommitdiff
path: root/other-patches
diff options
context:
space:
mode:
authorJohn Denker <jsd@av8n.com>2012-06-01 18:58:45 -0700
committerJohn Denker <jsd@av8n.com>2012-06-01 18:58:45 -0700
commitb732a73bc773789894466b0e5320b2f1fe42c7e9 (patch)
tree385358983f064a1f10a5080b33a3ba13010886db /other-patches
parent634d365a03cb0581a062cd3cf4db9ae69f1cde26 (diff)
original, as downloaded from http://www.qmail.org/netqmail-1.06.tar.gz
Diffstat (limited to 'other-patches')
-rw-r--r--other-patches/README51
-rw-r--r--other-patches/checkpassword-0.90.errno.patch12
-rw-r--r--other-patches/daemontools-0.76.errno.patch12
-rw-r--r--other-patches/djbdns-1.05.errno.patch12
-rw-r--r--other-patches/dot-forward-0.71.errno.patch12
-rw-r--r--other-patches/fastforward-0.51.errno.patch22
-rw-r--r--other-patches/mess822-0.58.errno.patch33
-rw-r--r--other-patches/qmailanalog-0.70.errno.patch87
-rw-r--r--other-patches/serialmail-0.75.errno.patch23
-rw-r--r--other-patches/ucspi-tcp-0.88.a_record.patch64
-rw-r--r--other-patches/ucspi-tcp-0.88.errno.patch12
-rw-r--r--other-patches/ucspi-tcp-0.88.nodefaultrbl.patch28
12 files changed, 368 insertions, 0 deletions
diff --git a/other-patches/README b/other-patches/README
new file mode 100644
index 0000000..9fc7e78
--- /dev/null
+++ b/other-patches/README
@@ -0,0 +1,51 @@
+If you have glibc-2.3.1 or later then none of the software written by
+djb will compile because of an incompatible declaration of errno.
+
+Here you can find patches correcting this problem for software likely
+you need if you run qmail.
+
+To use the patches
+==================
+
+From the top distribution directory, apply the appropriate errno patch
+with -p1. So, for example, for mess822, you would do
+
+tar zxvf mess822-0.58.tar.gz
+cd mess822-0.58
+patch -p1 < /path/to/mess822-0.58.errno.patch
+
+In case of daemontools, you need the following adjustment:
+
+tar zxvf daemontools-0.76.tar.gz
+cd admin/daemontools-0.76
+patch -p1 /path/to/daemontools-0.76.errno.patch
+
+Notes
+-----
+
+ucspi-tcp:
+
+ In addition to the errno patch, there are two other patches
+ included here; both update rblsmtpd's behavior to current
+ practices on the net.
+
+ The a_record patch allows you to specify the error that will
+ be returned by rblsmtpd for a zone that has only A records in
+ it.
+
+ The nodefaultrbl patch changes the behavior of rblsmtpd so
+ that if no `-r' flag is given, than instead of falling back to
+ rbl.maps.vix.com as the default RBL, rblsmtpd assumes that no
+ RBL is to be used.
+
+qmailanalog:
+
+ In addition to the required errno change, the qmailanalog
+ patch also changes qmailanalog to accept both tai and tai64n
+ times. This is necessary because djb never updated qmailanalog
+ after he changed daemontools to tai64n.
+
+These notes were originally written by Mate Wierdl, and have been
+modified for this distribution by Russell Nelson, and then were rewritten
+by Mate again, and then added to by Russell Nelson.
+
diff --git a/other-patches/checkpassword-0.90.errno.patch b/other-patches/checkpassword-0.90.errno.patch
new file mode 100644
index 0000000..1412ca0
--- /dev/null
+++ b/other-patches/checkpassword-0.90.errno.patch
@@ -0,0 +1,12 @@
+diff -u checkpassword-0.90.old/error.h checkpassword-0.90/error.h
+--- checkpassword-0.90.old/error.h 2000-12-23 00:40:46.000000000 -0600
++++ checkpassword-0.90/error.h 2003-01-14 00:49:57.000000000 -0600
+@@ -1,7 +1,7 @@
+ #ifndef ERROR_H
+ #define ERROR_H
+
+-extern int errno;
++#include <errno.h>
+
+ extern int error_intr;
+ extern int error_nomem;
diff --git a/other-patches/daemontools-0.76.errno.patch b/other-patches/daemontools-0.76.errno.patch
new file mode 100644
index 0000000..d1884f5
--- /dev/null
+++ b/other-patches/daemontools-0.76.errno.patch
@@ -0,0 +1,12 @@
+diff -ur daemontools-0.76.old/src/error.h daemontools-0.76/src/error.h
+--- daemontools-0.76.old/src/error.h 2001-07-12 11:49:49.000000000 -0500
++++ daemontools-0.76/src/error.h 2003-01-09 21:52:01.000000000 -0600
+@@ -3,7 +3,7 @@
+ #ifndef ERROR_H
+ #define ERROR_H
+
+-extern int errno;
++#include <errno.h>
+
+ extern int error_intr;
+ extern int error_nomem;
diff --git a/other-patches/djbdns-1.05.errno.patch b/other-patches/djbdns-1.05.errno.patch
new file mode 100644
index 0000000..5099c16
--- /dev/null
+++ b/other-patches/djbdns-1.05.errno.patch
@@ -0,0 +1,12 @@
+diff -u djbdns-1.05.old/error.h djbdns-1.05/error.h
+--- djbdns-1.05.old/error.h 2001-02-11 15:11:23.000000000 -0600
++++ djbdns-1.05/error.h 2003-01-08 16:08:42.000000000 -0600
+@@ -1,7 +1,7 @@
+ #ifndef ERROR_H
+ #define ERROR_H
+
+-extern int errno;
++#include <errno.h>
+
+ extern int error_intr;
+ extern int error_nomem;
diff --git a/other-patches/dot-forward-0.71.errno.patch b/other-patches/dot-forward-0.71.errno.patch
new file mode 100644
index 0000000..fb21349
--- /dev/null
+++ b/other-patches/dot-forward-0.71.errno.patch
@@ -0,0 +1,12 @@
+diff -u dot-forward-0.71.orig/error.h dot-forward-0.71/error.h
+--- dot-forward-0.71.orig/error.h 1998-05-19 05:15:50.000000000 -0500
++++ dot-forward-0.71/error.h 2004-01-29 11:16:01.000000000 -0600
+@@ -1,7 +1,7 @@
+ #ifndef ERROR_H
+ #define ERROR_H
+
+-extern int errno;
++#include <errno.h>
+
+ extern int error_intr;
+ extern int error_nomem;
diff --git a/other-patches/fastforward-0.51.errno.patch b/other-patches/fastforward-0.51.errno.patch
new file mode 100644
index 0000000..8dc0d4a
--- /dev/null
+++ b/other-patches/fastforward-0.51.errno.patch
@@ -0,0 +1,22 @@
+diff -u fastforward-0.51.orig/cdb_seek.c fastforward-0.51/cdb_seek.c
+--- fastforward-0.51.orig/cdb_seek.c 1998-05-19 11:25:42.000000000 -0500
++++ fastforward-0.51/cdb_seek.c 2004-01-29 11:22:24.000000000 -0600
+@@ -1,6 +1,5 @@
+ #include <sys/types.h>
+ #include <errno.h>
+-extern int errno;
+ #include "cdb.h"
+
+ #ifndef SEEK_SET
+diff -u fastforward-0.51.orig/error.h fastforward-0.51/error.h
+--- fastforward-0.51.orig/error.h 1998-05-19 11:25:42.000000000 -0500
++++ fastforward-0.51/error.h 2004-01-29 11:14:47.000000000 -0600
+@@ -1,7 +1,7 @@
+ #ifndef ERROR_H
+ #define ERROR_H
+
+-extern int errno;
++#include <errno.h>
+
+ extern int error_intr;
+ extern int error_nomem;
diff --git a/other-patches/mess822-0.58.errno.patch b/other-patches/mess822-0.58.errno.patch
new file mode 100644
index 0000000..172396e
--- /dev/null
+++ b/other-patches/mess822-0.58.errno.patch
@@ -0,0 +1,33 @@
+diff -u mess822-0.58.old/cdb_seek.c mess822-0.58/cdb_seek.c
+--- mess822-0.58.old/cdb_seek.c 1998-09-04 21:33:37.000000000 -0500
++++ mess822-0.58/cdb_seek.c 2003-01-13 23:17:30.000000000 -0600
+@@ -1,6 +1,5 @@
+ #include <sys/types.h>
+ #include <errno.h>
+-extern int errno;
+ #include "cdb.h"
+
+ #ifndef SEEK_SET
+diff -u mess822-0.58.old/error.h mess822-0.58/error.h
+--- mess822-0.58.old/error.h 1998-09-04 21:33:37.000000000 -0500
++++ mess822-0.58/error.h 2003-01-13 23:18:09.000000000 -0600
+@@ -1,7 +1,7 @@
+ #ifndef ERROR_H
+ #define ERROR_H
+
+-extern int errno;
++#include <errno.h>
+
+ extern int error_intr;
+ extern int error_nomem;
+diff -u mess822-0.58.old/leapsecs_read.c mess822-0.58/leapsecs_read.c
+--- mess822-0.58.old/leapsecs_read.c 1998-09-04 21:33:37.000000000 -0500
++++ mess822-0.58/leapsecs_read.c 2003-01-13 23:19:17.000000000 -0600
+@@ -2,7 +2,6 @@
+ #include <sys/stat.h>
+ #include <fcntl.h>
+ #include <errno.h>
+-extern int errno;
+ #include "tai.h"
+ #include "leapsecs.h"
+
diff --git a/other-patches/qmailanalog-0.70.errno.patch b/other-patches/qmailanalog-0.70.errno.patch
new file mode 100644
index 0000000..94f4583
--- /dev/null
+++ b/other-patches/qmailanalog-0.70.errno.patch
@@ -0,0 +1,87 @@
+diff -u orig/error.3 ./error.3
+--- orig/error.3 1998-08-30 17:39:27.000000000 -0400
++++ ./error.3 2004-09-06 12:17:26.000000000 -0400
+@@ -3,8 +3,8 @@
+ error \- syscall error codes
+ .SH SYNTAX
+ .B #include <error.h>
+-
+-extern int \fBerrno\fP;
++.br
++.B #include <errno.h>
+
+ extern int \fBerror_intr\fP;
+ .br
+diff -u orig/error.c ./error.c
+--- orig/error.c 1998-08-30 17:39:27.000000000 -0400
++++ ./error.c 2004-09-06 12:17:26.000000000 -0400
+@@ -1,4 +1,3 @@
+-#include <errno.h>
+ #include "error.h"
+
+ /* warning: as coverage improves here, should update error_{str,temp} */
+diff -u orig/error.h ./error.h
+--- orig/error.h 1998-08-30 17:39:27.000000000 -0400
++++ ./error.h 2004-09-06 12:17:26.000000000 -0400
+@@ -1,7 +1,7 @@
+ #ifndef ERROR_H
+ #define ERROR_H
+
+-extern int errno;
++#include <errno.h>
+
+ extern int error_intr;
+ extern int error_nomem;
+diff -u orig/Makefile ./Makefile
+--- orig/Makefile 1998-08-30 17:39:26.000000000 -0400
++++ ./Makefile 2004-09-06 12:17:26.000000000 -0400
+@@ -259,7 +259,7 @@
+ matchup.o: \
+ compile matchup.c stralloc.h gen_alloc.h gen_alloc.h gen_allocdefs.h \
+ strerr.h getln.h substdio.h subfd.h substdio.h readwrite.h exit.h \
+-str.h fmt.h scan.h case.h
++str.h fmt.h scan.h case.h alloc.h
+ ./compile matchup.c
+
+ open.a: \
+diff -u orig/matchup.c ./matchup.c
+--- orig/matchup.c 1998-08-30 17:39:27.000000000 -0400
++++ ./matchup.c 2004-09-06 12:23:20.000000000 -0400
+@@ -1,3 +1,4 @@
++#include "alloc.h"
+ #include "stralloc.h"
+ #include "gen_alloc.h"
+ #include "gen_allocdefs.h"
+@@ -439,6 +440,32 @@
+ if (getln(subfdin,&line,&match,'\n') == -1) die_read();
+ if (!match) break;
+
++ if (line.s[0] == '@' && line.len >= 25) {
++ unsigned long secs;
++ unsigned long nanosecs;
++ unsigned long u;
++
++ secs = 0;
++ nanosecs = 0;
++ for (i = 1; i < line.len;i++) {
++ u = line.s[i] - '0';
++ if (u >= 10) {
++ u = line.s[i] - 'a';
++ if (u >= 6) break;
++ u += 10;
++ }
++ secs <<= 4;
++ secs += nanosecs >> 28;
++ nanosecs &= 0xfffffff;
++ nanosecs <<= 4;
++ nanosecs += u;
++ }
++ secs -= 4611686018427387914ULL;
++ i = fmt_uint0(line.s,secs,9);
++ line.s[i++] = '.';
++ i += fmt_uint0(line.s+i,nanosecs,9);
++ while (i < 25) line.s[i++] = ' ';
++ }
+ if (!stralloc_copy(&outline,&line)) nomem();
+
+ for (i = 0;i < line.len;++i) {
diff --git a/other-patches/serialmail-0.75.errno.patch b/other-patches/serialmail-0.75.errno.patch
new file mode 100644
index 0000000..bf01d1b
--- /dev/null
+++ b/other-patches/serialmail-0.75.errno.patch
@@ -0,0 +1,23 @@
+diff -u serialmail-0.75.orig/error.h serialmail-0.75/error.h
+--- serialmail-0.75.orig/error.h 1998-11-14 20:28:23.000000000 -0600
++++ serialmail-0.75/error.h 2004-01-29 11:15:32.000000000 -0600
+@@ -1,7 +1,7 @@
+ #ifndef ERROR_H
+ #define ERROR_H
+
+-extern int errno;
++#include <errno.h>
+
+ extern int error_intr;
+ extern int error_nomem;
+diff -u serialmail-0.75.orig/leapsecs_read.c serialmail-0.75/leapsecs_read.c
+--- serialmail-0.75.orig/leapsecs_read.c 1998-11-14 20:28:23.000000000 -0600
++++ serialmail-0.75/leapsecs_read.c 2004-01-29 11:20:09.000000000 -0600
+@@ -2,7 +2,6 @@
+ #include <sys/stat.h>
+ #include <fcntl.h>
+ #include <errno.h>
+-extern int errno;
+ #include "tai.h"
+ #include "leapsecs.h"
+
diff --git a/other-patches/ucspi-tcp-0.88.a_record.patch b/other-patches/ucspi-tcp-0.88.a_record.patch
new file mode 100644
index 0000000..903125e
--- /dev/null
+++ b/other-patches/ucspi-tcp-0.88.a_record.patch
@@ -0,0 +1,64 @@
+diff -ruN --exclude conf-* ucspi-tcp-0.88/rblsmtpd.c ucspi-tcp-0.88.fix/rblsmtpd.c
+--- ucspi-tcp-0.88/rblsmtpd.c Sat Mar 18 10:18:42 2000
++++ ucspi-tcp-0.88.fix/rblsmtpd.c Wed Aug 9 16:42:33 2000
+@@ -60,16 +60,54 @@
+
+ void rbl(char *base)
+ {
++ int i;
++ char *altreply = 0;
+ if (decision) return;
+ if (!stralloc_copy(&tmp,&ip_reverse)) nomem();
++ i = str_chr(base, ':');
++ if (base[i]) {
++ base[i] = 0;
++ altreply = base+i+1;
++ }
+ if (!stralloc_cats(&tmp,base)) nomem();
+- if (dns_txt(&text,&tmp) == -1) {
+- flagmustnotbounce = 1;
+- if (flagfailclosed) {
+- if (!stralloc_copys(&text,"temporary RBL lookup error")) nomem();
+- decision = 2;
++ if (altreply) {
++ if (dns_ip4(&text,&tmp) == -1) {
++ flagmustnotbounce = 1;
++ if (flagfailclosed) {
++ if (!stralloc_copys(&text,"temporary RBL lookup error")) nomem();
++ decision = 2;
++ }
++ return;
++ }
++ if (text.len) {
++ if(!stralloc_copys(&text, "")) nomem();
++ while(*altreply) {
++ char *x;
++ i = str_chr(altreply, '%');
++ if(!stralloc_catb(&text, altreply, i)) nomem();
++ if(altreply[i] &&
++ altreply[i+1]=='I' &&
++ altreply[i+2]=='P' &&
++ altreply[i+3]=='%') {
++ if(!stralloc_catb(&text, ip_env, str_len(ip_env))) nomem();
++ altreply+=i+4;
++ } else if(altreply[i]) {
++ if(!stralloc_cats(&text, "%")) nomem();
++ altreply+=i+1;
++ } else {
++ altreply+=i;
++ }
++ }
++ }
++ } else {
++ if (dns_txt(&text,&tmp) == -1) {
++ flagmustnotbounce = 1;
++ if (flagfailclosed) {
++ if (!stralloc_copys(&text,"temporary RBL lookup error")) nomem();
++ decision = 2;
++ }
++ return;
+ }
+- return;
+ }
+ if (text.len)
+ if (flagrblbounce)
diff --git a/other-patches/ucspi-tcp-0.88.errno.patch b/other-patches/ucspi-tcp-0.88.errno.patch
new file mode 100644
index 0000000..fd93909
--- /dev/null
+++ b/other-patches/ucspi-tcp-0.88.errno.patch
@@ -0,0 +1,12 @@
+diff -u ucspi-tcp-0.88.old/error.h ucspi-tcp-0.88/error.h
+--- ucspi-tcp-0.88.old/error.h 2000-03-18 09:18:20.000000000 -0600
++++ ucspi-tcp-0.88/error.h 2003-01-08 13:39:12.000000000 -0600
+@@ -1,7 +1,7 @@
+ #ifndef ERROR_H
+ #define ERROR_H
+
+-extern int errno;
++#include <errno.h>
+
+ extern int error_intr;
+ extern int error_nomem;
diff --git a/other-patches/ucspi-tcp-0.88.nodefaultrbl.patch b/other-patches/ucspi-tcp-0.88.nodefaultrbl.patch
new file mode 100644
index 0000000..fd9e90e
--- /dev/null
+++ b/other-patches/ucspi-tcp-0.88.nodefaultrbl.patch
@@ -0,0 +1,28 @@
+diff -ur ucspi-tcp-0.88.orig/rblsmtpd.c ucspi-tcp-0.88/rblsmtpd.c
+--- ucspi-tcp-0.88.orig/rblsmtpd.c Thu Jan 16 14:33:56 2003
++++ ucspi-tcp-0.88/rblsmtpd.c Thu Jan 16 14:38:17 2003
+@@ -155,7 +155,6 @@
+
+ main(int argc,char **argv,char **envp)
+ {
+- int flagwantdefaultrbl = 1;
+ char *x;
+ int opt;
+
+@@ -182,7 +181,7 @@
+ case 'c': flagfailclosed = 1; break;
+ case 'C': flagfailclosed = 0; break;
+ case 't': scan_ulong(optarg,&timeout); break;
+- case 'r': rbl(optarg); flagwantdefaultrbl = 0; break;
++ case 'r': rbl(optarg); break;
+ case 'a': antirbl(optarg); break;
+ default: usage();
+ }
+@@ -190,7 +189,6 @@
+ argv += optind;
+ if (!*argv) usage();
+
+- if (flagwantdefaultrbl) rbl("rbl.maps.vix.com");
+ if (decision >= 2) rblsmtpd();
+
+ pathexec_run(*argv,argv,envp);