Remove superflous header includes from isc/util.h header
Formerly, isc/util.h would pull a few extra headers (isc/list.h, isc/attributes.h, isc/result.h and errno.h). These includes were removed in favor of including them directly when used.
This commit is contained in:
@@ -14,7 +14,6 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
#include <stdlib.h>
|
|
||||||
|
|
||||||
/*! \file isc/rwlock.h */
|
/*! \file isc/rwlock.h */
|
||||||
|
|
||||||
@@ -28,6 +27,7 @@ typedef enum {
|
|||||||
} isc_rwlocktype_t;
|
} isc_rwlocktype_t;
|
||||||
|
|
||||||
#if USE_PTHREAD_RWLOCK
|
#if USE_PTHREAD_RWLOCK
|
||||||
|
#include <errno.h>
|
||||||
#include <pthread.h>
|
#include <pthread.h>
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -38,6 +38,8 @@ typedef enum {
|
|||||||
|
|
||||||
#if ISC_TRACK_PTHREADS_OBJECTS
|
#if ISC_TRACK_PTHREADS_OBJECTS
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
typedef pthread_rwlock_t *isc_rwlock_t;
|
typedef pthread_rwlock_t *isc_rwlock_t;
|
||||||
typedef pthread_rwlock_t isc__rwlock_t;
|
typedef pthread_rwlock_t isc__rwlock_t;
|
||||||
|
|
||||||
|
|||||||
@@ -27,8 +27,6 @@
|
|||||||
* ISC_ or isc_ to the name.
|
* ISC_ or isc_ to the name.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <isc/attributes.h>
|
|
||||||
|
|
||||||
/***
|
/***
|
||||||
*** Clang Compatibility Macros
|
*** Clang Compatibility Macros
|
||||||
***/
|
***/
|
||||||
@@ -122,8 +120,6 @@
|
|||||||
#define ISC_UTIL_TRACE(a)
|
#define ISC_UTIL_TRACE(a)
|
||||||
#endif /* ifdef ISC_UTIL_TRACEON */
|
#endif /* ifdef ISC_UTIL_TRACEON */
|
||||||
|
|
||||||
#include <isc/result.h> /* Contractual promise. */
|
|
||||||
|
|
||||||
#define SPINLOCK(sp) \
|
#define SPINLOCK(sp) \
|
||||||
{ \
|
{ \
|
||||||
ISC_UTIL_TRACE(fprintf(stderr, "SPINLOCKING %p %s %d\n", (sp), \
|
ISC_UTIL_TRACE(fprintf(stderr, "SPINLOCKING %p %s %d\n", (sp), \
|
||||||
@@ -218,11 +214,6 @@
|
|||||||
INSIST(locktype == isc_rwlocktype_write); \
|
INSIST(locktype == isc_rwlocktype_write); \
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* List Macros.
|
|
||||||
*/
|
|
||||||
#include <isc/list.h> /* Contractual promise. */
|
|
||||||
|
|
||||||
/*%
|
/*%
|
||||||
* Performance
|
* Performance
|
||||||
*/
|
*/
|
||||||
@@ -318,8 +309,6 @@ mock_assert(const int result, const char *const expression,
|
|||||||
/*
|
/*
|
||||||
* Errors
|
* Errors
|
||||||
*/
|
*/
|
||||||
#include <errno.h> /* for errno */
|
|
||||||
|
|
||||||
#include <isc/error.h> /* Contractual promise. */
|
#include <isc/error.h> /* Contractual promise. */
|
||||||
#include <isc/strerr.h> /* for ISC_STRERRORSIZE */
|
#include <isc/strerr.h> /* for ISC_STRERRORSIZE */
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user