mirror of
https://github.com/isc-projects/bind9.git
synced 2026-06-13 20:20:00 -04:00
Remove legacy support for AIX
This commit is contained in:
parent
9a8da1e25a
commit
f0f71420c8
22 changed files with 48 additions and 271 deletions
|
|
@ -147,7 +147,7 @@ Minimally, BIND requires a UNIX or Linux system with an ANSI C compiler,
|
|||
basic POSIX support, and a 64-bit integer type. Successful builds have been
|
||||
observed on many versions of Linux and UNIX, including RedHat, Fedora,
|
||||
Debian, Ubuntu, SuSE, Slackware, FreeBSD, NetBSD, OpenBSD, Mac OS X,
|
||||
Solaris, HP-UX, AIX, SCO OpenServer, and OpenWRT.
|
||||
Solaris, HP-UX, and OpenWRT.
|
||||
|
||||
BIND requires a cryptography provider library such as OpenSSL or a
|
||||
hardware service module supporting PKCS#11. On Linux, BIND requires
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@
|
|||
#include "dnssectool.h"
|
||||
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX 1024 /* AIX, WIN32, and others don't define this. */
|
||||
#define PATH_MAX 1024 /* WIN32, and others don't define this. */
|
||||
#endif
|
||||
|
||||
const char *program = "dnssec-cds";
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@
|
|||
#include "dnssectool.h"
|
||||
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX 1024 /* AIX, WIN32, and others don't define this. */
|
||||
#define PATH_MAX 1024 /* WIN32, and others don't define this. */
|
||||
#endif
|
||||
|
||||
const char *program = "dnssec-dsfromkey";
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@
|
|||
#include "dnssectool.h"
|
||||
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX 1024 /* AIX, WIN32, and others don't define this. */
|
||||
#define PATH_MAX 1024 /* WIN32, and others don't define this. */
|
||||
#endif
|
||||
|
||||
const char *program = "dnssec-importkey";
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@
|
|||
#include "dnssectool.h"
|
||||
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX 1024 /* AIX, WIN32, and others don't define this. */
|
||||
#define PATH_MAX 1024 /* WIN32, and others don't define this. */
|
||||
#endif
|
||||
|
||||
const char *program = "dnssec-signzone";
|
||||
|
|
|
|||
|
|
@ -410,7 +410,7 @@ key_collision(dst_key_t *dstkey, dns_name_t *name, const char *dir,
|
|||
uint16_t id, oldid;
|
||||
uint32_t rid, roldid;
|
||||
dns_secalg_t alg;
|
||||
char filename[ISC_DIR_NAMEMAX];
|
||||
char filename[NAME_MAX];
|
||||
isc_buffer_t fileb;
|
||||
isc_stdtime_t now;
|
||||
|
||||
|
|
|
|||
|
|
@ -110,8 +110,8 @@ LIBDNS_EXTERNAL_DATA extern unsigned int dns_zone_mkey_day;
|
|||
LIBDNS_EXTERNAL_DATA extern unsigned int dns_zone_mkey_month;
|
||||
|
||||
static bool want_stats = false;
|
||||
static char program_name[ISC_DIR_NAMEMAX] = "named";
|
||||
static char absolute_conffile[ISC_DIR_PATHMAX];
|
||||
static char program_name[NAME_MAX] = "named";
|
||||
static char absolute_conffile[PATH_MAX];
|
||||
static char saved_command_line[512];
|
||||
static char version[512];
|
||||
static unsigned int maxsocks = 0;
|
||||
|
|
|
|||
|
|
@ -19,8 +19,6 @@ case $host in
|
|||
use_threads=false ;;
|
||||
*-solaris*)
|
||||
use_threads=true ;;
|
||||
*-ibm-aix*)
|
||||
use_threads=true ;;
|
||||
*-hp-hpux10*)
|
||||
use_threads=false ;;
|
||||
*-hp-hpux11*)
|
||||
|
|
@ -51,7 +49,7 @@ case $host in
|
|||
*-freebsd*)
|
||||
use_threads=true ;;
|
||||
*-linux*)
|
||||
use_threads=true ;;
|
||||
use_threads=true ;;
|
||||
*-darwin[[123456789]].*)
|
||||
use_threads=false ;;
|
||||
*-darwin*.*)
|
||||
|
|
@ -81,7 +79,7 @@ if $use_threads
|
|||
then
|
||||
AC_MSG_RESULT(yes)
|
||||
else
|
||||
AC_MSG_RESULT(no)
|
||||
AC_MSG_RESULT(no)
|
||||
fi
|
||||
|
||||
if $use_threads
|
||||
|
|
@ -94,7 +92,7 @@ then
|
|||
# We don't want to set -lpthread as that break
|
||||
# the ability to choose threads library at final
|
||||
# link time and is not valid for all architectures.
|
||||
|
||||
|
||||
PTHREAD=
|
||||
if test "X$GCC" = "Xyes"; then
|
||||
saved_cc="$CC"
|
||||
|
|
|
|||
80
configure
vendored
80
configure
vendored
|
|
@ -760,7 +760,6 @@ ISC_PLATFORM_NEEDIN6ADDRANY
|
|||
ISC_PLATFORM_HAVEINADDR6
|
||||
ISC_PLATFORM_HAVEIPV6
|
||||
BIND9_CO_RULE
|
||||
LIBTOOL_IN_MAIN
|
||||
LIBTOOL_ALLOW_UNDEFINED
|
||||
LIBTOOL_MODE_UNINSTALL
|
||||
LIBTOOL_MODE_LINK
|
||||
|
|
@ -15808,10 +15807,6 @@ $as_echo "yes" >&6; }
|
|||
case "$host" in
|
||||
*) LIBTOOL_ALLOW_UNDEFINED= ;;
|
||||
esac
|
||||
case "$host" in
|
||||
*-ibm-aix*) LIBTOOL_IN_MAIN="-Wl,-bI:T_testlist.imp" ;;
|
||||
*) LIBTOOL_IN_MAIN= ;;
|
||||
esac;
|
||||
;;
|
||||
*)
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
|
|
@ -15826,7 +15821,6 @@ $as_echo "no" >&6; }
|
|||
LIBTOOL_MODE_LINK=
|
||||
LIBTOOL_MODE_UNINSTALL=
|
||||
LIBTOOL_ALLOW_UNDEFINED=
|
||||
LIBTOOL_IN_MAIN=
|
||||
INSTALL_LIBRARY='${INSTALL_DATA}'
|
||||
;;
|
||||
esac
|
||||
|
|
@ -17910,7 +17904,6 @@ SA=a
|
|||
|
||||
|
||||
|
||||
|
||||
BIND9_CO_RULE=".c.$O:"
|
||||
|
||||
|
||||
|
|
@ -19339,9 +19332,6 @@ IRS_PLATFORM_USEDECLSPEC="#undef IRS_PLATFORM_USEDECLSPEC"
|
|||
ISC_PLATFORM_BRACEPTHREADONCEINIT="#undef ISC_PLATFORM_BRACEPTHREADONCEINIT"
|
||||
|
||||
case "$host" in
|
||||
*-aix5.[123].*)
|
||||
hack_shutup_pthreadonceinit=yes
|
||||
;;
|
||||
*-solaris2.[89])
|
||||
hack_shutup_pthreadonceinit=yes
|
||||
;;
|
||||
|
|
@ -19519,70 +19509,7 @@ fi
|
|||
|
||||
case "$enable_atomic" in
|
||||
yes|''|autodetect)
|
||||
case "$host" in
|
||||
powerpc-ibm-aix*)
|
||||
if test "X$GCC" = "Xyes"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if asm(\"ics\"); works" >&5
|
||||
$as_echo_n "checking if asm(\"ics\"); works... " >&6; }
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
|
||||
main() { asm("ics"); exit(0); }
|
||||
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
|
||||
$as_echo "yes" >&6; }
|
||||
use_atomic=yes
|
||||
else
|
||||
|
||||
saved_cflags="$CFLAGS"
|
||||
CFLAGS="$CFLAGS -Wa,-many"
|
||||
if test "$cross_compiling" = yes; then :
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: cross compile, assume yes" >&5
|
||||
$as_echo "cross compile, assume yes" >&6; }
|
||||
CFLAGS="$saved_cflags"
|
||||
use_atomic=yes
|
||||
else
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
main() { asm("ics"); exit(0); }
|
||||
|
||||
_ACEOF
|
||||
if ac_fn_c_try_run "$LINENO"; then :
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, required -Wa,-many" >&5
|
||||
$as_echo "yes, required -Wa,-many" >&6; }
|
||||
use_atomic=yes
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no, use_atomic disabled" >&5
|
||||
$as_echo "no, use_atomic disabled" >&6; }
|
||||
CFLAGS="$saved_cflags"
|
||||
use_atomic=no
|
||||
fi
|
||||
rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
|
||||
conftest.$ac_objext conftest.beam conftest.$ac_ext
|
||||
fi
|
||||
|
||||
|
||||
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
else
|
||||
use_atomic=yes
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
use_atomic=yes
|
||||
;;
|
||||
esac
|
||||
use_atomic=yes
|
||||
;;
|
||||
no)
|
||||
have_stdatomic=no
|
||||
|
|
@ -19776,9 +19703,6 @@ if ac_fn_c_try_compile "$LINENO"; then :
|
|||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
;;
|
||||
powerpc-ibm-aix*)
|
||||
compiler=aix
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
case "$compiler" in
|
||||
|
|
@ -19788,8 +19712,6 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
|||
osf)
|
||||
ISC_PLATFORM_USEOSFASM="#define ISC_PLATFORM_USEOSFASM 1"
|
||||
;;
|
||||
aix)
|
||||
;;
|
||||
mac)
|
||||
;;
|
||||
*)
|
||||
|
|
|
|||
48
configure.in
48
configure.in
|
|
@ -956,10 +956,6 @@ case $use_libtool in
|
|||
case "$host" in
|
||||
*) LIBTOOL_ALLOW_UNDEFINED= ;;
|
||||
esac
|
||||
case "$host" in
|
||||
*-ibm-aix*) LIBTOOL_IN_MAIN="-Wl,-bI:T_testlist.imp" ;;
|
||||
*) LIBTOOL_IN_MAIN= ;;
|
||||
esac;
|
||||
;;
|
||||
*)
|
||||
AC_MSG_RESULT(no)
|
||||
|
|
@ -973,7 +969,6 @@ case $use_libtool in
|
|||
LIBTOOL_MODE_LINK=
|
||||
LIBTOOL_MODE_UNINSTALL=
|
||||
LIBTOOL_ALLOW_UNDEFINED=
|
||||
LIBTOOL_IN_MAIN=
|
||||
INSTALL_LIBRARY='${INSTALL_DATA}'
|
||||
;;
|
||||
esac
|
||||
|
|
@ -1998,7 +1993,6 @@ AC_SUBST(LIBTOOL_MODE_INSTALL)
|
|||
AC_SUBST(LIBTOOL_MODE_LINK)
|
||||
AC_SUBST(LIBTOOL_MODE_UNINSTALL)
|
||||
AC_SUBST(LIBTOOL_ALLOW_UNDEFINED)
|
||||
AC_SUBST(LIBTOOL_IN_MAIN)
|
||||
|
||||
BIND9_CO_RULE=".c.$O:"
|
||||
AC_SUBST(BIND9_CO_RULE)
|
||||
|
|
@ -2726,9 +2720,6 @@ AC_SUBST(ISC_PLATFORM_BRACEPTHREADONCEINIT)
|
|||
ISC_PLATFORM_BRACEPTHREADONCEINIT="#undef ISC_PLATFORM_BRACEPTHREADONCEINIT"
|
||||
|
||||
case "$host" in
|
||||
*-aix5.[[123]].*)
|
||||
hack_shutup_pthreadonceinit=yes
|
||||
;;
|
||||
[*-solaris2.[89]])
|
||||
hack_shutup_pthreadonceinit=yes
|
||||
;;
|
||||
|
|
@ -2808,39 +2799,7 @@ AC_ARG_ENABLE(atomic,
|
|||
enable_atomic="autodetect")
|
||||
case "$enable_atomic" in
|
||||
yes|''|autodetect)
|
||||
case "$host" in
|
||||
powerpc-ibm-aix*)
|
||||
if test "X$GCC" = "Xyes"; then
|
||||
AC_MSG_CHECKING([if asm("ics"); works])
|
||||
AC_TRY_COMPILE(,[
|
||||
main() { asm("ics"); exit(0); }
|
||||
],
|
||||
[AC_MSG_RESULT(yes)
|
||||
use_atomic=yes],
|
||||
[
|
||||
saved_cflags="$CFLAGS"
|
||||
CFLAGS="$CFLAGS -Wa,-many"
|
||||
AC_TRY_RUN([
|
||||
main() { asm("ics"); exit(0); }
|
||||
],
|
||||
[AC_MSG_RESULT([yes, required -Wa,-many])
|
||||
use_atomic=yes],
|
||||
[AC_MSG_RESULT([no, use_atomic disabled])
|
||||
CFLAGS="$saved_cflags"
|
||||
use_atomic=no],
|
||||
[AC_MSG_RESULT([cross compile, assume yes])
|
||||
CFLAGS="$saved_cflags"
|
||||
use_atomic=yes])
|
||||
]
|
||||
)
|
||||
else
|
||||
use_atomic=yes
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
use_atomic=yes
|
||||
;;
|
||||
esac
|
||||
use_atomic=yes
|
||||
;;
|
||||
no)
|
||||
have_stdatomic=no
|
||||
|
|
@ -2951,9 +2910,6 @@ if test "yes" = "$have_atomic"; then
|
|||
return (0);],
|
||||
[compiler=osf],)
|
||||
;;
|
||||
powerpc-ibm-aix*)
|
||||
compiler=aix
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
case "$compiler" in
|
||||
|
|
@ -2963,8 +2919,6 @@ if test "yes" = "$have_atomic"; then
|
|||
osf)
|
||||
ISC_PLATFORM_USEOSFASM="#define ISC_PLATFORM_USEOSFASM 1"
|
||||
;;
|
||||
aix)
|
||||
;;
|
||||
mac)
|
||||
;;
|
||||
*)
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@
|
|||
|
||||
/*
|
||||
* Copyright (C) 1999-2001, 2016 Internet Systems Consortium, Inc. ("ISC")
|
||||
*
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
|
@ -84,7 +84,7 @@ typedef struct config_data {
|
|||
typedef struct dir_entry dir_entry_t;
|
||||
|
||||
struct dir_entry {
|
||||
char dirpath[ISC_DIR_PATHMAX];
|
||||
char dirpath[PATH_MAX];
|
||||
ISC_LINK(dir_entry_t) link;
|
||||
};
|
||||
|
||||
|
|
@ -361,7 +361,7 @@ process_dir(isc_dir_t *dir, void *passback, config_data_t *cd,
|
|||
dlist_t *dir_list, unsigned int basedirlen)
|
||||
{
|
||||
|
||||
char tmp[ISC_DIR_PATHMAX + ISC_DIR_NAMEMAX];
|
||||
char tmp[PATH_MAX + NAME_MAX];
|
||||
int astPos;
|
||||
struct stat sb;
|
||||
isc_result_t result = ISC_R_FAILURE;
|
||||
|
|
@ -369,7 +369,7 @@ process_dir(isc_dir_t *dir, void *passback, config_data_t *cd,
|
|||
char *type;
|
||||
char *ttlStr;
|
||||
char *data;
|
||||
char host[ISC_DIR_NAMEMAX];
|
||||
char host[NAME_MAX];
|
||||
char *tmpString;
|
||||
char *tmpPtr;
|
||||
int ttl;
|
||||
|
|
@ -408,7 +408,7 @@ process_dir(isc_dir_t *dir, void *passback, config_data_t *cd,
|
|||
{
|
||||
if ((strlen(host) +
|
||||
strlen(tmpPtr + 1) + 2)
|
||||
> ISC_DIR_NAMEMAX)
|
||||
> NAME_MAX)
|
||||
continue;
|
||||
strcat(host, tmpPtr + 1);
|
||||
strcat(host, ".");
|
||||
|
|
@ -416,7 +416,7 @@ process_dir(isc_dir_t *dir, void *passback, config_data_t *cd,
|
|||
}
|
||||
if ((strlen(host) +
|
||||
strlen(tmpString) + 1)
|
||||
<= ISC_DIR_NAMEMAX)
|
||||
<= NAME_MAX)
|
||||
strcat(host, tmpString);
|
||||
}
|
||||
|
||||
|
|
@ -443,7 +443,7 @@ process_dir(isc_dir_t *dir, void *passback, config_data_t *cd,
|
|||
strncpy(host,
|
||||
(char *) &dir->entry.name[6],
|
||||
sizeof(host) - 1);
|
||||
host[255] = '\0';
|
||||
host[NAME_MAX-1] = '\0';
|
||||
}
|
||||
foundHost = true;
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ The sources are checked out, and the web reports are generated,
|
|||
on bb, as driven by the following cron jobs:
|
||||
|
||||
# Check out the current bind 9 version and make the source tarball.
|
||||
# Argument to maketar.sh should be v9_0 for 9.0 release branch,
|
||||
# Argument to maketar.sh should be v9_0 for 9.0 release branch,
|
||||
# HEAD for mainline.
|
||||
35 2-22 * * * PLATFORM=BSD-3.1 && . $HOME/b9t/hosts/$PLATFORM/env && \
|
||||
nice sh $HOME/b9t/bin/maketar.sh HEAD \
|
||||
|
|
@ -57,7 +57,6 @@ The current test schedule is as follows:
|
|||
:00 Most tests begin
|
||||
:45 Status report generator runs (was :30)
|
||||
|
||||
aix: I can't seem to access that machine; it appears to be down.
|
||||
bb: Build starts at top of hour, 0300 to 2200
|
||||
durango: Build starts at top of hour, 0300 to 2200
|
||||
trantor: Build starts at top of hour, 0300 to 2100, odd-numbered hours
|
||||
|
|
|
|||
|
|
@ -17,11 +17,6 @@ socket API to be usable. The systems which do not follow this will
|
|||
currently not get any warnings or errors, but ipv6 will simply not
|
||||
function on them.
|
||||
|
||||
These systems currently include, but are not limited to:
|
||||
|
||||
AIX 3.4 (with ipv6 patches)
|
||||
|
||||
|
||||
RUN-TIME ISSUES
|
||||
---------------
|
||||
|
||||
|
|
@ -108,4 +103,3 @@ RELEVANT RFCs
|
|||
3493: Basic Socket Interface Extensions for IPv6
|
||||
|
||||
3542: Advanced Sockets Application Program Interface (API) for IPv6
|
||||
|
||||
|
|
|
|||
|
|
@ -784,7 +784,7 @@ dns_dnssec_findzonekeys(dns_db_t *db, dns_dbversion_t *ver,
|
|||
isc_result_t result2;
|
||||
isc_buffer_t buf;
|
||||
|
||||
isc_buffer_init(&buf, filename, ISC_DIR_NAMEMAX);
|
||||
isc_buffer_init(&buf, filename, NAME_MAX);
|
||||
result2 = dst_key_getfilename(dst_key_name(pubkey),
|
||||
dst_key_id(pubkey),
|
||||
dst_key_alg(pubkey),
|
||||
|
|
@ -1676,7 +1676,7 @@ dns_dnssec_keylistfromrdataset(const dns_name_t *origin,
|
|||
isc_result_t result2;
|
||||
isc_buffer_t buf;
|
||||
|
||||
isc_buffer_init(&buf, filename, ISC_DIR_NAMEMAX);
|
||||
isc_buffer_init(&buf, filename, NAME_MAX);
|
||||
result2 = dst_key_getfilename(dst_key_name(pubkey),
|
||||
dst_key_id(pubkey),
|
||||
dst_key_alg(pubkey),
|
||||
|
|
|
|||
|
|
@ -484,7 +484,7 @@ dst_key_fromfile(dns_name_t *name, dns_keytag_t id,
|
|||
isc_mem_t *mctx, dst_key_t **keyp)
|
||||
{
|
||||
isc_result_t result;
|
||||
char filename[ISC_DIR_NAMEMAX];
|
||||
char filename[NAME_MAX];
|
||||
isc_buffer_t buf;
|
||||
dst_key_t *key;
|
||||
|
||||
|
|
@ -498,7 +498,7 @@ dst_key_fromfile(dns_name_t *name, dns_keytag_t id,
|
|||
|
||||
key = NULL;
|
||||
|
||||
isc_buffer_init(&buf, filename, ISC_DIR_NAMEMAX);
|
||||
isc_buffer_init(&buf, filename, NAME_MAX);
|
||||
result = dst_key_getfilename(name, id, alg, type, NULL, mctx, &buf);
|
||||
if (result != ISC_R_SUCCESS)
|
||||
goto out;
|
||||
|
|
@ -1605,7 +1605,7 @@ write_public_key(const dst_key_t *key, int type, const char *directory) {
|
|||
FILE *fp;
|
||||
isc_buffer_t keyb, textb, fileb, classb;
|
||||
isc_region_t r;
|
||||
char filename[ISC_DIR_NAMEMAX];
|
||||
char filename[NAME_MAX];
|
||||
unsigned char key_array[DST_KEY_MAXSIZE];
|
||||
char text_array[DST_KEY_MAXTEXTSIZE];
|
||||
char class_array[10];
|
||||
|
|
|
|||
|
|
@ -624,7 +624,7 @@ dst__privstruct_writefile(const dst_key_t *key, const dst_private_t *priv,
|
|||
{
|
||||
FILE *fp;
|
||||
isc_result_t result;
|
||||
char filename[ISC_DIR_NAMEMAX];
|
||||
char filename[NAME_MAX];
|
||||
char buffer[MAXFIELDSIZE * 2];
|
||||
isc_fsaccess_t access;
|
||||
isc_stdtime_t when;
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@
|
|||
#define LOG_BUFFER_SIZE (8 * 1024)
|
||||
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX 1024 /* AIX and others don't define this. */
|
||||
#define PATH_MAX 1024 /* WIN32 and others don't define this. */
|
||||
#endif
|
||||
|
||||
/*!
|
||||
|
|
|
|||
|
|
@ -38,63 +38,7 @@
|
|||
* case.
|
||||
*/
|
||||
|
||||
#if defined(_AIX)
|
||||
|
||||
#include <sys/atomic_op.h>
|
||||
|
||||
#define isc_atomic_store(p, v) _clear_lock(p, v)
|
||||
|
||||
#ifdef __GNUC__
|
||||
static inline int32_t
|
||||
#else
|
||||
static int32_t
|
||||
#endif
|
||||
isc_atomic_xadd(int32_t *p, int32_t val) {
|
||||
int ret;
|
||||
|
||||
#ifdef __GNUC__
|
||||
asm("ics");
|
||||
#else
|
||||
__isync();
|
||||
#endif
|
||||
|
||||
ret = fetch_and_add((atomic_p)p, (int)val);
|
||||
|
||||
#ifdef __GNUC__
|
||||
asm("ics");
|
||||
#else
|
||||
__isync();
|
||||
#endif
|
||||
|
||||
return (ret);
|
||||
}
|
||||
|
||||
#ifdef __GNUC__
|
||||
static inline int
|
||||
#else
|
||||
static int
|
||||
#endif
|
||||
isc_atomic_cmpxchg(atomic_p p, int old, int replacement) {
|
||||
int orig = old;
|
||||
|
||||
#ifdef __GNUC__
|
||||
asm("ics");
|
||||
#else
|
||||
__isync();
|
||||
#endif
|
||||
if (compare_and_swap(p, &orig, replacement))
|
||||
orig = old;
|
||||
|
||||
#ifdef __GNUC__
|
||||
asm("ics");
|
||||
#else
|
||||
__isync();
|
||||
#endif
|
||||
|
||||
return (orig);
|
||||
}
|
||||
|
||||
#elif defined(ISC_PLATFORM_USEGCCASM) || defined(ISC_PLATFORM_USEMACASM)
|
||||
#if defined(ISC_PLATFORM_USEGCCASM) || defined(ISC_PLATFORM_USEMACASM)
|
||||
static inline int32_t
|
||||
isc_atomic_xadd(int32_t *p, int32_t val) {
|
||||
int32_t orig;
|
||||
|
|
|
|||
|
|
@ -20,29 +20,24 @@
|
|||
#include <isc/lang.h>
|
||||
#include <isc/result.h>
|
||||
|
||||
#define ISC_DIR_NAMEMAX 256
|
||||
#define ISC_DIR_PATHMAX 1024
|
||||
#ifndef NAME_MAX
|
||||
#define NAME_MAX 256
|
||||
#endif
|
||||
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX 1024
|
||||
#endif
|
||||
|
||||
/*% Directory Entry */
|
||||
typedef struct isc_direntry {
|
||||
/*!
|
||||
* Ideally, this should be NAME_MAX, but AIX does not define it by
|
||||
* default and dynamically allocating the space based on pathconf()
|
||||
* complicates things undesirably, as does adding special conditionals
|
||||
* just for AIX. So a comfortably sized buffer is chosen instead.
|
||||
*/
|
||||
char name[ISC_DIR_NAMEMAX];
|
||||
char name[NAME_MAX];
|
||||
unsigned int length;
|
||||
} isc_direntry_t;
|
||||
|
||||
/*% Directory */
|
||||
typedef struct isc_dir {
|
||||
unsigned int magic;
|
||||
/*!
|
||||
* As with isc_direntry_t->name, making this "right" for all systems
|
||||
* is slightly problematic because AIX does not define PATH_MAX.
|
||||
*/
|
||||
char dirname[ISC_DIR_PATHMAX];
|
||||
char dirname[PATH_MAX];
|
||||
isc_direntry_t entry;
|
||||
DIR * handle;
|
||||
} isc_dir_t;
|
||||
|
|
|
|||
|
|
@ -823,39 +823,6 @@ socket_log(isc__socket_t *sock, const isc_sockaddr_t *address,
|
|||
}
|
||||
}
|
||||
|
||||
#if defined(_AIX) && defined(ISC_NET_BSD44MSGHDR) && \
|
||||
defined(USE_CMSG) && defined(IPV6_RECVPKTINFO)
|
||||
/*
|
||||
* AIX has a kernel bug where IPV6_RECVPKTINFO gets cleared by
|
||||
* setting IPV6_V6ONLY.
|
||||
*/
|
||||
static void
|
||||
FIX_IPV6_RECVPKTINFO(isc__socket_t *sock)
|
||||
{
|
||||
char strbuf[ISC_STRERRORSIZE];
|
||||
int on = 1;
|
||||
|
||||
if (sock->pf != AF_INET6 || sock->type != isc_sockettype_udp)
|
||||
return;
|
||||
|
||||
if (setsockopt(sock->fd, IPPROTO_IPV6, IPV6_RECVPKTINFO,
|
||||
(void *)&on, sizeof(on)) < 0) {
|
||||
|
||||
isc__strerror(errno, strbuf, sizeof(strbuf));
|
||||
UNEXPECTED_ERROR(__FILE__, __LINE__,
|
||||
"setsockopt(%d, IPV6_RECVPKTINFO) "
|
||||
"%s: %s", sock->fd,
|
||||
isc_msgcat_get(isc_msgcat,
|
||||
ISC_MSGSET_GENERAL,
|
||||
ISC_MSG_FAILED,
|
||||
"failed"),
|
||||
strbuf);
|
||||
}
|
||||
}
|
||||
#else
|
||||
#define FIX_IPV6_RECVPKTINFO(sock) (void)0
|
||||
#endif
|
||||
|
||||
/*%
|
||||
* Increment socket-related statistics counters.
|
||||
*/
|
||||
|
|
@ -6168,7 +6135,6 @@ isc__socket_ipv6only(isc_socket_t *sock0, bool yes) {
|
|||
strbuf);
|
||||
}
|
||||
}
|
||||
FIX_IPV6_RECVPKTINFO(sock); /* AIX */
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -19,18 +19,23 @@
|
|||
#include <isc/lang.h>
|
||||
#include <isc/result.h>
|
||||
|
||||
#define ISC_DIR_NAMEMAX _MAX_FNAME
|
||||
#define ISC_DIR_PATHMAX _MAX_PATH
|
||||
#ifndef NAME_MAX
|
||||
#define NAME_MAX _MAX_FNAME
|
||||
#endif
|
||||
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX _MAX_PATH
|
||||
#endif
|
||||
|
||||
typedef struct {
|
||||
char name[ISC_DIR_NAMEMAX];
|
||||
char name[NAME_MAX];
|
||||
unsigned int length;
|
||||
WIN32_FIND_DATA find_data;
|
||||
} isc_direntry_t;
|
||||
|
||||
typedef struct {
|
||||
unsigned int magic;
|
||||
char dirname[ISC_DIR_PATHMAX];
|
||||
char dirname[PATH_MAX];
|
||||
isc_direntry_t entry;
|
||||
bool entry_filled;
|
||||
HANDLE search_handle;
|
||||
|
|
|
|||
|
|
@ -2965,7 +2965,7 @@ parser_complain(cfg_parser_t *pctx, bool is_warning,
|
|||
va_list args)
|
||||
{
|
||||
char tokenbuf[MAX_LOG_TOKEN + 10];
|
||||
static char where[ISC_DIR_PATHMAX + 100];
|
||||
static char where[PATH_MAX + 100];
|
||||
static char message[2048];
|
||||
int level = ISC_LOG_ERROR;
|
||||
const char *prep = "";
|
||||
|
|
|
|||
Loading…
Reference in a new issue