Gitweb:
http://git.exim.org/exim.git/commitdiff/9c19b270ead379003ece51fb49b83e7ea8b2d25e
Commit: 9c19b270ead379003ece51fb49b83e7ea8b2d25e
Parent: 627d1a1b61d9c535835221afcbe1b9cd6548cd3b
Author: Jeremy Harris <jgh146exb@???>
AuthorDate: Sun Apr 26 18:31:14 2015 +0100
Committer: Jeremy Harris <jgh146exb@???>
CommitDate: Sun Apr 26 18:31:14 2015 +0100
Invert default for iconv() 2nd arg type, to match SUSv3. Bug 1161
Probably most of the lesser-used builds are already broken;
this won't fix them
---
src/OS/os.h-AIX | 4 ++++
src/OS/os.h-BSDI | 3 +++
src/OS/os.h-DGUX | 3 +++
src/OS/os.h-Darwin | 3 +++
src/OS/os.h-DragonFly | 3 +++
src/OS/os.h-FreeBSD | 3 +++
src/OS/os.h-GNU | 3 +++
src/OS/os.h-GNUkFreeBSD | 3 +++
src/OS/os.h-GNUkNetBSD | 3 +++
src/OS/os.h-HI-OSF | 3 +++
src/OS/os.h-HI-UX | 3 +++
src/OS/os.h-HP-UX | 1 -
src/OS/os.h-HP-UX-9 | 3 +++
src/OS/os.h-IRIX | 3 ---
src/OS/os.h-IRIX6 | 3 ---
src/OS/os.h-IRIX632 | 3 ---
src/OS/os.h-IRIX65 | 3 ---
src/OS/os.h-Linux | 3 ---
src/OS/os.h-NetBSD | 3 +++
src/OS/os.h-OSF1 | 3 ---
src/OS/os.h-OpenBSD | 3 +++
src/OS/os.h-OpenUNIX | 3 +++
src/OS/os.h-QNX | 3 +++
src/OS/os.h-SCO | 3 +++
src/OS/os.h-SCO_SV | 3 +++
src/OS/os.h-SunOS4 | 3 +++
src/OS/os.h-SunOS5 | 3 +++
src/OS/os.h-SunOS5-hal | 3 +++
src/OS/os.h-ULTRIX | 3 +++
src/OS/os.h-UNIX_SV | 3 +++
src/OS/os.h-USG | 3 +++
src/OS/os.h-Unixware7 | 1 -
src/OS/os.h-cygwin | 3 +++
src/OS/os.h-mips | 3 +++
src/src/exim.h | 2 +-
35 files changed, 80 insertions(+), 21 deletions(-)
diff --git a/src/OS/os.h-AIX b/src/OS/os.h-AIX
index f3a84f2..5cd4501 100644
--- a/src/OS/os.h-AIX
+++ b/src/OS/os.h-AIX
@@ -20,4 +20,8 @@
typedef struct flock flock_t;
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
+
/* End */
diff --git a/src/OS/os.h-BSDI b/src/OS/os.h-BSDI
index cd91936..6e16722 100644
--- a/src/OS/os.h-BSDI
+++ b/src/OS/os.h-BSDI
@@ -8,4 +8,7 @@
typedef struct flock flock_t;
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-DGUX b/src/OS/os.h-DGUX
index 838ddd9..9040f0e 100644
--- a/src/OS/os.h-DGUX
+++ b/src/OS/os.h-DGUX
@@ -22,4 +22,7 @@ forego the detection of some source-routing based IP attacks. */
#define NO_IP_OPTIONS
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-Darwin b/src/OS/os.h-Darwin
index 559003f..f408740 100644
--- a/src/OS/os.h-Darwin
+++ b/src/OS/os.h-Darwin
@@ -42,4 +42,7 @@ updating Exim to use the newer interface. */
#define OFF_T_FMT "%lld"
#define LONGLONG_T long int
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-DragonFly b/src/OS/os.h-DragonFly
index 669bb23..4c2f1d5 100644
--- a/src/OS/os.h-DragonFly
+++ b/src/OS/os.h-DragonFly
@@ -7,4 +7,7 @@
typedef struct flock flock_t;
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-FreeBSD b/src/OS/os.h-FreeBSD
index c5ed042..ba4889f 100644
--- a/src/OS/os.h-FreeBSD
+++ b/src/OS/os.h-FreeBSD
@@ -10,4 +10,7 @@
typedef struct flock flock_t;
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-GNU b/src/OS/os.h-GNU
index cc4da0e..4499316 100644
--- a/src/OS/os.h-GNU
+++ b/src/OS/os.h-GNU
@@ -17,4 +17,7 @@ typedef struct flock flock_t;
/* Hurd-specific bits below */
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-GNUkFreeBSD b/src/OS/os.h-GNUkFreeBSD
index e60690f..ab35031 100644
--- a/src/OS/os.h-GNUkFreeBSD
+++ b/src/OS/os.h-GNUkFreeBSD
@@ -19,4 +19,7 @@ typedef struct flock flock_t;
#define HAVE_SYS_MOUNT_H
#define SIOCGIFCONF_GIVES_ADDR
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-GNUkNetBSD b/src/OS/os.h-GNUkNetBSD
index 121f2d3..bc3bc25 100644
--- a/src/OS/os.h-GNUkNetBSD
+++ b/src/OS/os.h-GNUkNetBSD
@@ -19,4 +19,7 @@ typedef struct flock flock_t;
#define HAVE_SYS_MOUNT_H
#define SIOCGIFCONF_GIVES_ADDR
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-HI-OSF b/src/OS/os.h-HI-OSF
index 76bd429..0f50fb6 100644
--- a/src/OS/os.h-HI-OSF
+++ b/src/OS/os.h-HI-OSF
@@ -6,4 +6,7 @@ typedef struct flock flock_t;
#define F_FREESP O_TRUNC
#define DN_EXPAND_ARG4_TYPE u_char *
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-HI-UX b/src/OS/os.h-HI-UX
index 97b83ed..f3df963 100644
--- a/src/OS/os.h-HI-UX
+++ b/src/OS/os.h-HI-UX
@@ -15,4 +15,7 @@
typedef struct flock flock_t;
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-HP-UX b/src/OS/os.h-HP-UX
index 87e4dfc..3359204 100644
--- a/src/OS/os.h-HP-UX
+++ b/src/OS/os.h-HP-UX
@@ -1,6 +1,5 @@
/* Exim: OS-specific C header file for HP-UX versions greater than 9 */
-#define ICONV_ARG2_TYPE char **
#define EXIM_SOCKLEN_T size_t
#define LOAD_AVG_NEEDS_ROOT
diff --git a/src/OS/os.h-HP-UX-9 b/src/OS/os.h-HP-UX-9
index dab965e..5a260d6 100644
--- a/src/OS/os.h-HP-UX-9
+++ b/src/OS/os.h-HP-UX-9
@@ -17,4 +17,7 @@
typedef struct flock flock_t;
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-IRIX b/src/OS/os.h-IRIX
index ac5a6b3..1d4bf46 100644
--- a/src/OS/os.h-IRIX
+++ b/src/OS/os.h-IRIX
@@ -14,7 +14,4 @@
#define F_FAVAIL f_favail
#define vfork fork
-/* Other OS have "const" in here */
-#define ICONV_ARG2_TYPE char **
-
/* End */
diff --git a/src/OS/os.h-IRIX6 b/src/OS/os.h-IRIX6
index c41a234..bf30767 100644
--- a/src/OS/os.h-IRIX6
+++ b/src/OS/os.h-IRIX6
@@ -13,7 +13,4 @@
#define F_FAVAIL f_favail
#define vfork fork
-/* Other OS have "const" in here */
-#define ICONV_ARG2_TYPE char **
-
/* End */
diff --git a/src/OS/os.h-IRIX632 b/src/OS/os.h-IRIX632
index 0196931..90f1c58 100644
--- a/src/OS/os.h-IRIX632
+++ b/src/OS/os.h-IRIX632
@@ -15,7 +15,4 @@
#define F_FAVAIL f_favail
#define vfork fork
-/* Other OS have "const" in here */
-#define ICONV_ARG2_TYPE char **
-
/* End */
diff --git a/src/OS/os.h-IRIX65 b/src/OS/os.h-IRIX65
index 683c66a..4b248fe 100644
--- a/src/OS/os.h-IRIX65
+++ b/src/OS/os.h-IRIX65
@@ -13,7 +13,4 @@
#define F_FAVAIL f_favail
#define vfork fork
-/* Other OS have "const" in here */
-#define ICONV_ARG2_TYPE char **
-
/* End */
diff --git a/src/OS/os.h-Linux b/src/OS/os.h-Linux
index 3fead17..05c153e 100644
--- a/src/OS/os.h-Linux
+++ b/src/OS/os.h-Linux
@@ -44,9 +44,6 @@ storage" as quickly as Exim thinks they are. */
#define NEED_SYNC_DIRECTORY
-/* Other OS have "const" in here */
-#define ICONV_ARG2_TYPE char **
-
#define os_find_running_interfaces os_find_running_interfaces_linux
/* Need a prototype for the Linux-specific function. The structure hasn't
diff --git a/src/OS/os.h-NetBSD b/src/OS/os.h-NetBSD
index 19a8ac0..d2d3e0d 100644
--- a/src/OS/os.h-NetBSD
+++ b/src/OS/os.h-NetBSD
@@ -22,4 +22,7 @@ typedef struct flock flock_t;
#define HAVE_SYS_STATVFS_H
#endif
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-OSF1 b/src/OS/os.h-OSF1
index f04a5b7..6b5fa49 100644
--- a/src/OS/os.h-OSF1
+++ b/src/OS/os.h-OSF1
@@ -13,7 +13,4 @@ changed. */
/* Still not "socklen_t", which is the most common setting */
#define EXIM_SOCKLEN_T int
-/* The default for this is "const char **" */
-#define ICONV_ARG2_TYPE char **
-
/* End */
diff --git a/src/OS/os.h-OpenBSD b/src/OS/os.h-OpenBSD
index 9578047..35eddd5 100644
--- a/src/OS/os.h-OpenBSD
+++ b/src/OS/os.h-OpenBSD
@@ -20,4 +20,7 @@ typedef struct flock flock_t;
typedef struct __res_state *res_state;
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-OpenUNIX b/src/OS/os.h-OpenUNIX
index 90be8d5..67d1063 100644
--- a/src/OS/os.h-OpenUNIX
+++ b/src/OS/os.h-OpenUNIX
@@ -13,4 +13,7 @@
#define _SVID3
#define NEED_H_ERRNO
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-QNX b/src/OS/os.h-QNX
index 106b0a6..798f799 100644
--- a/src/OS/os.h-QNX
+++ b/src/OS/os.h-QNX
@@ -18,4 +18,7 @@ doesn't have/need this header file. From Karsten P. Hoffmann. */
extern int h_errno;
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-SCO b/src/OS/os.h-SCO
index 07d21bd..e5e915e 100644
--- a/src/OS/os.h-SCO
+++ b/src/OS/os.h-SCO
@@ -15,4 +15,7 @@
#define _SVID3
#define NEED_H_ERRNO
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-SCO_SV b/src/OS/os.h-SCO_SV
index 486fcbe..0ca29f7 100644
--- a/src/OS/os.h-SCO_SV
+++ b/src/OS/os.h-SCO_SV
@@ -13,4 +13,7 @@
#define _SVID3
#define NEED_H_ERRNO
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-SunOS4 b/src/OS/os.h-SunOS4
index b0deefc..6555620 100644
--- a/src/OS/os.h-SunOS4
+++ b/src/OS/os.h-SunOS4
@@ -33,4 +33,7 @@ flag causes this to get done in exim.h. */
#define FUDGE_GETC_AND_FRIENDS
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-SunOS5 b/src/OS/os.h-SunOS5
index 8bc0799..dd14f25 100644
--- a/src/OS/os.h-SunOS5
+++ b/src/OS/os.h-SunOS5
@@ -28,4 +28,7 @@ it seems. */
#define PAM_CONVERSE_ARG2_TYPE struct pam_message
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-SunOS5-hal b/src/OS/os.h-SunOS5-hal
index 044e09b..cd9e877 100644
--- a/src/OS/os.h-SunOS5-hal
+++ b/src/OS/os.h-SunOS5-hal
@@ -8,4 +8,7 @@
#define LOAD_AVG_SYMBOL "avenrun_1min"
#define LOAD_AVG_FIELD value.ul
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-ULTRIX b/src/OS/os.h-ULTRIX
index 9985af2..08db5ae 100644
--- a/src/OS/os.h-ULTRIX
+++ b/src/OS/os.h-ULTRIX
@@ -12,4 +12,7 @@ a minority operating system, easiest just to say "no" until someone asks. */
#define NO_OPENLOG
typedef struct flock flock_t;
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-UNIX_SV b/src/OS/os.h-UNIX_SV
index 9ad824a..4943a07 100644
--- a/src/OS/os.h-UNIX_SV
+++ b/src/OS/os.h-UNIX_SV
@@ -19,4 +19,7 @@
#define _SVID3
#define NEED_H_ERRNO
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-USG b/src/OS/os.h-USG
index 1c780ee..e769220 100644
--- a/src/OS/os.h-USG
+++ b/src/OS/os.h-USG
@@ -13,4 +13,7 @@
#define _SVID3
#define NEED_H_ERRNO
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-Unixware7 b/src/OS/os.h-Unixware7
index 1592094..4d3ed42 100644
--- a/src/OS/os.h-Unixware7
+++ b/src/OS/os.h-Unixware7
@@ -2,7 +2,6 @@
#define NO_SYSEXITS
-#define ICONV_ARG2_TYPE char **
#define EXIM_SOCKLEN_T size_t
#define LOAD_AVG_NEEDS_ROOT
diff --git a/src/OS/os.h-cygwin b/src/OS/os.h-cygwin
index 740300a..07c14d0 100644
--- a/src/OS/os.h-cygwin
+++ b/src/OS/os.h-cygwin
@@ -48,4 +48,7 @@ struct { \
DWORD SubAuthority[n]; \
} name = { SID_REVISION, n, {SECURITY_NT_AUTHORITY}, {sid}}
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/OS/os.h-mips b/src/OS/os.h-mips
index 79f3ff2..325e3a1 100644
--- a/src/OS/os.h-mips
+++ b/src/OS/os.h-mips
@@ -21,4 +21,7 @@ extern char *strerror(int);
extern int sys_nerr;
extern char *sys_errlist[];
+/* default is non-const */
+#define ICONV_ARG2_TYPE const char **
+
/* End */
diff --git a/src/src/exim.h b/src/src/exim.h
index fb48a43..48cf8c1 100644
--- a/src/src/exim.h
+++ b/src/src/exim.h
@@ -418,7 +418,7 @@ iconv(). It's os.h file defines ICONV_ARG2_TYPE. For the rest, define a default
here. */
#ifndef ICONV_ARG2_TYPE
-# define ICONV_ARG2_TYPE const char **
+# define ICONV_ARG2_TYPE char **
#endif
/* One OS uses a different type for the 5th argument of getsockopt */