ccollect:0.6.2->0.7.0
[nslu2-linux/optware.git] / sources / tcpwrappers.patch
blob7fb7543ff0a1aa19ea5323012d7638f977b95878
1 --- Makefile Sun Sep 12 03:37:58 2004
2 +++ tcp_wrappers.makefile.new Sun Sep 12 03:37:47 2004
3 @@ -143,7 +143,7 @@
5 linux:
6 @make REAL_DAEMON_DIR=$(REAL_DAEMON_DIR) STYLE=$(STYLE) \
7 - LIBS= RANLIB=ranlib ARFLAGS=rv AUX_OBJ=setenv.o \
8 + LIBS= ARFLAGS=rv AUX_OBJ=setenv.o \
9 NETGROUP= TLI= EXTRA_CFLAGS="-DBROKEN_SO_LINGER" all
11 # This is good for many SYSV+BSD hybrids with NIS, probably also for HP-UX 7.x.
12 @@ -375,7 +375,7 @@
13 # library; some don't care as long as the modules are in the right order;
14 # some systems don't even have a ranlib(1) command. Make your choice.
16 -RANLIB = ranlib # have ranlib (BSD-ish UNIX)
17 +#RANLIB = ranlib # have ranlib (BSD-ish UNIX)
18 #RANLIB = echo # no ranlib (SYSV-ish UNIX)
20 ARFLAGS = rv # most systems
21 @@ -590,7 +590,7 @@
22 # look for access control information. Watch out for the quotes and
23 # backslashes when you make changes.
25 -TABLES = -DHOSTS_DENY=\"/etc/hosts.deny\" -DHOSTS_ALLOW=\"/etc/hosts.allow\"
26 +TABLES = -DHOSTS_DENY=\"/opt/etc/hosts.deny\" -DHOSTS_ALLOW=\"/opt/etc/hosts.allow\" -DSYS_ERRLIST_DEFINED
28 ####################################################
29 # Optional: dealing with host name/address conflicts
30 --- tcp_wrappers_7.6/percent_m.c 1994-12-28 17:42:37.000000000 +0100
31 +++ tcpwrappers/percent_m.c 2006-05-29 11:49:52.000000000 +0200
32 @@ -13,10 +13,6 @@
33 #include <string.h>
35 extern int errno;
36 -#ifndef SYS_ERRLIST_DEFINED
37 -extern char *sys_errlist[];
38 -extern int sys_nerr;
39 -#endif
41 #include "mystdarg.h"
43 @@ -29,11 +25,7 @@
45 while (*bp = *cp)
46 if (*cp == '%' && cp[1] == 'm') {
47 - if (errno < sys_nerr && errno > 0) {
48 - strcpy(bp, sys_errlist[errno]);
49 - } else {
50 - sprintf(bp, "Unknown error %d", errno);
51 - }
52 + strcpy(bp, strerror(errno));
53 bp += strlen(bp);
54 cp += 2;
55 } else {
56 --- tcp_wrappers_7.6/tli.c 1997-03-21 19:27:26.000000000 +0100
57 +++ tcpwrappers/tli.c 2006-05-29 11:51:51.000000000 +0200
58 @@ -40,8 +40,6 @@
60 extern char *nc_sperror();
61 extern int errno;
62 -extern char *sys_errlist[];
63 -extern int sys_nerr;
64 extern int t_errno;
65 extern char *t_errlist[];
66 extern int t_nerr;
67 @@ -305,12 +303,7 @@
68 return (t_errlist[t_errno]);
70 } else {
71 - if (errno < 0 || errno >= sys_nerr) {
72 - sprintf(buf, "Unknown UNIX error %d", errno);
73 - return (buf);
74 - } else {
75 - return (sys_errlist[errno]);
76 - }
77 + return (strerror(errno));