Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
ISC Open Source Projects
BIND
Commits
b454c031
Commit
b454c031
authored
Mar 04, 2014
by
Evan Hunt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[master] use ANSI prototypes, clean up some casts
parent
e7c0d42b
Changes
36
Hide whitespace changes
Inline
Side-by-side
Showing
36 changed files
with
70 additions
and
70 deletions
+70
-70
bin/dnssec/dnssec-signzone.c
bin/dnssec/dnssec-signzone.c
+1
-1
bin/dnssec/dnssec-verify.c
bin/dnssec/dnssec-verify.c
+2
-1
bin/named/main.c
bin/named/main.c
+1
-1
bin/named/unix/os.c
bin/named/unix/os.c
+1
-1
bin/named/win32/ntservice.c
bin/named/win32/ntservice.c
+3
-3
bin/named/win32/os.c
bin/named/win32/os.c
+1
-1
bin/pkcs11/pkcs11-keygen.c
bin/pkcs11/pkcs11-keygen.c
+1
-1
bin/tests/resolver/t_resolver.c
bin/tests/resolver/t_resolver.c
+1
-1
bin/tests/zone_test.c
bin/tests/zone_test.c
+1
-1
bin/tools/nsec3hash.c
bin/tools/nsec3hash.c
+3
-2
lib/dns/ecdb.c
lib/dns/ecdb.c
+12
-9
lib/dns/geoip.c
lib/dns/geoip.c
+1
-1
lib/dns/openssl_link.c
lib/dns/openssl_link.c
+1
-2
lib/dns/rbt.c
lib/dns/rbt.c
+2
-4
lib/dns/rbtdb.c
lib/dns/rbtdb.c
+0
-2
lib/dns/tests/dbversion_test.c
lib/dns/tests/dbversion_test.c
+2
-2
lib/dns/tests/dispatch_test.c
lib/dns/tests/dispatch_test.c
+1
-1
lib/dns/tests/dnstest.c
lib/dns/tests/dnstest.c
+5
-5
lib/irs/context.c
lib/irs/context.c
+1
-1
lib/isc/app_api.c
lib/isc/app_api.c
+6
-6
lib/isc/backtrace.c
lib/isc/backtrace.c
+1
-1
lib/isc/hash.c
lib/isc/hash.c
+2
-2
lib/isc/lib.c
lib/isc/lib.c
+1
-1
lib/isc/mem.c
lib/isc/mem.c
+1
-1
lib/isc/task.c
lib/isc/task.c
+1
-1
lib/isc/tests/isctest.c
lib/isc/tests/isctest.c
+3
-3
lib/isc/tests/socket_test.c
lib/isc/tests/socket_test.c
+1
-1
lib/isc/timer.c
lib/isc/timer.c
+1
-1
lib/isc/unix/app.c
lib/isc/unix/app.c
+3
-3
lib/isc/unix/net.c
lib/isc/unix/net.c
+2
-2
lib/isc/unix/socket.c
lib/isc/unix/socket.c
+1
-1
lib/isc/win32/app.c
lib/isc/win32/app.c
+3
-3
lib/isc/win32/net.c
lib/isc/win32/net.c
+1
-1
lib/isc/win32/ntpaths.c
lib/isc/win32/ntpaths.c
+1
-1
lib/isc/win32/socket.c
lib/isc/win32/socket.c
+1
-1
lib/isc/win32/syslog.c
lib/isc/win32/syslog.c
+1
-1
No files found.
bin/dnssec/dnssec-signzone.c
View file @
b454c031
...
...
@@ -2574,7 +2574,7 @@ report(const char *format, ...) {
}
static
void
build_final_keylist
()
{
build_final_keylist
(
void
)
{
isc_result_t
result
;
dns_dbversion_t
*
ver
=
NULL
;
dns_diff_t
diff
;
...
...
bin/dnssec/dnssec-verify.c
View file @
b454c031
...
...
@@ -165,7 +165,8 @@ main(int argc, char *argv[]) {
#endif
char
*
classname
=
NULL
;
dns_rdataclass_t
rdclass
;
char
ch
,
*
endp
;
char
*
endp
;
int
ch
;
#define CMDLINE_FLAGS \
"m:o:I:c:E:v:xz"
...
...
bin/named/main.c
View file @
b454c031
...
...
@@ -735,7 +735,7 @@ destroy_managers(void) {
}
static
void
dump_symboltable
()
{
dump_symboltable
(
void
)
{
int
i
;
isc_result_t
result
;
const
char
*
fname
;
...
...
bin/named/unix/os.c
View file @
b454c031
...
...
@@ -607,7 +607,7 @@ ns_os_changeuser(void) {
}
void
ns_os_adjustnofile
()
{
ns_os_adjustnofile
(
void
)
{
#ifdef HAVE_LINUXTHREADS
isc_result_t
result
;
isc_resourcevalue_t
newvalue
;
...
...
bin/named/win32/ntservice.c
View file @
b454c031
...
...
@@ -44,7 +44,7 @@ int bindmain(int, char *[]); /* From main.c */
* Initialize the Service by registering it.
*/
void
ntservice_init
()
{
ntservice_init
(
void
)
{
if
(
!
foreground
)
{
/* Register handler with the SCM */
hServiceStatus
=
RegisterServiceCtrlHandler
(
BIND_SERVICE_NAME
,
...
...
@@ -64,14 +64,14 @@ ntservice_init() {
}
void
ntservice_shutdown
()
{
ntservice_shutdown
(
void
)
{
UpdateSCM
(
SERVICE_STOPPED
);
}
/*
* Routine to check if this is a service or a foreground program
*/
BOOL
ntservice_isservice
()
{
ntservice_isservice
(
void
)
{
return
(
!
foreground
);
}
/*
...
...
bin/named/win32/os.c
View file @
b454c031
...
...
@@ -56,7 +56,7 @@ static char *version_error =
"named requires Windows 2000 Service Pack 2 or later to run correctly"
;
void
ns_paths_init
()
{
ns_paths_init
(
void
)
{
if
(
!
Initialized
)
isc_ntpaths_init
();
...
...
bin/pkcs11/pkcs11-keygen.c
View file @
b454c031
...
...
@@ -250,7 +250,7 @@ keyclass_fromtext(const char *name) {
}
static
void
usage
()
{
usage
(
void
)
{
fprintf
(
stderr
,
"Usage:
\n
"
"
\t
pkcs11-keygen -a algorithm -b keysize -l label
\n
"
...
...
bin/tests/resolver/t_resolver.c
View file @
b454c031
...
...
@@ -104,7 +104,7 @@ destroy_resolver(dns_resolver_t **resolverp) {
}
static
void
test_dns_resolver_create
()
{
test_dns_resolver_create
(
void
)
{
dns_resolver_t
*
resolver
=
NULL
;
t_assert
(
"test_dns_resolver_create"
,
1
,
T_REQUIRED
,
"%s"
,
...
...
bin/tests/zone_test.c
View file @
b454c031
...
...
@@ -76,7 +76,7 @@ isc_sockaddr_t addr;
(void)NULL
static
void
usage
()
{
usage
(
void
)
{
fprintf
(
stderr
,
"usage: zone_test [-dqsSM] [-c class] [-f file] zone
\n
"
);
exit
(
1
);
...
...
bin/tools/nsec3hash.c
View file @
b454c031
...
...
@@ -59,8 +59,9 @@ check_result(isc_result_t result, const char *message) {
}
static
void
usage
()
{
printf
(
"Usage: %s salt algorithm iterations domain
\n
"
,
program
);
usage
(
void
)
{
fprintf
(
stderr
,
"Usage: %s salt algorithm iterations domain
\n
"
,
program
);
exit
(
1
);
}
...
...
lib/dns/ecdb.c
View file @
b454c031
...
...
@@ -14,8 +14,6 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: ecdb.c,v 1.10.34.1 2012/02/07 00:44:14 each Exp $ */
#include "config.h"
#include <isc/result.h>
...
...
@@ -775,19 +773,24 @@ rdataset_settrust(dns_rdataset_t *rdataset, dns_trust_t trust) {
static
void
rdatasetiter_destroy
(
dns_rdatasetiter_t
**
iteratorp
)
{
ecdb_rdatasetiter_t
*
ecdbiterator
;
isc_mem_t
*
mctx
;
union
{
dns_rdatasetiter_t
*
rdatasetiterator
;
ecdb_rdatasetiter_t
*
ecdbiterator
;
}
u
;
REQUIRE
(
iteratorp
!=
NULL
);
ecdbiterator
=
(
ecdb_rdatasetiter_t
*
)
*
iteratorp
;
REQUIRE
(
DNS_RDATASETITER_VALID
(
&
ecdbiterator
->
common
));
REQUIRE
(
DNS_RDATASETITER_VALID
(
*
iteratorp
));
mctx
=
ecdbiterator
->
common
.
db
->
mctx
;
u
.
rdatasetiterator
=
*
iteratorp
;
ecdbiterator
->
common
.
magic
=
0
;
mctx
=
u
.
ecdbiterator
->
common
.
db
->
mctx
;
u
.
ecdbiterator
->
common
.
magic
=
0
;
dns_db_detachnode
(
ecdbiterator
->
common
.
db
,
&
ecdbiterator
->
common
.
node
);
isc_mem_put
(
mctx
,
ecdbiterator
,
sizeof
(
ecdb_rdatasetiter_t
));
dns_db_detachnode
(
u
.
ecdbiterator
->
common
.
db
,
&
u
.
ecdbiterator
->
common
.
node
);
isc_mem_put
(
mctx
,
u
.
ecdbiterator
,
sizeof
(
ecdb_rdatasetiter_t
));
*
iteratorp
=
NULL
;
}
...
...
lib/dns/geoip.c
View file @
b454c031
...
...
@@ -208,7 +208,7 @@ set_state(unsigned int family, isc_uint32_t ipnum, const geoipv6_t *ipnum6,
}
static
geoip_state_t
*
get_state
()
{
get_state
(
void
)
{
#ifdef ISC_PLATFORM_USETHREADS
isc_result_t
result
;
geoip_state_t
*
state
;
...
...
lib/dns/openssl_link.c
View file @
b454c031
...
...
@@ -242,8 +242,7 @@ dst__openssl_init(const char *engine) {
}
void
dst__openssl_destroy
()
{
dst__openssl_destroy
(
void
)
{
/*
* Sequence taken from apps_shutdown() in <apps/apps.h>.
*/
...
...
lib/dns/rbt.c
View file @
b454c031
...
...
@@ -15,8 +15,6 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id$ */
/*! \file */
/* Principal Authors: DCL */
...
...
@@ -646,7 +644,7 @@ dns_rbt_serialize_tree(FILE *file, dns_rbt_t *rbt,
isc_crc64_final
(
&
crc
);
#ifdef DEBUG
hexdump
(
"serializing CRC"
,
crc
,
sizeof
(
crc
));
hexdump
(
"serializing CRC"
,
&
crc
,
sizeof
(
crc
));
#endif
/* Serialize header */
...
...
@@ -841,7 +839,7 @@ dns_rbt_deserialize_tree(void *base_address, size_t filesize,
isc_crc64_final
(
&
crc
);
#ifdef DEBUG
hexdump
(
"deserializing CRC"
,
crc
,
sizeof
(
crc
));
hexdump
(
"deserializing CRC"
,
&
crc
,
sizeof
(
crc
));
#endif
/* Check file hash */
...
...
lib/dns/rbtdb.c
View file @
b454c031
...
...
@@ -15,8 +15,6 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id$ */
/*! \file */
/*
...
...
lib/dns/tests/dbversion_test.c
View file @
b454c031
...
...
@@ -57,7 +57,7 @@ static dns_db_t *db1 = NULL, *db2 = NULL;
static
dns_dbversion_t
*
v1
=
NULL
,
*
v2
=
NULL
;
static
void
setup_db
()
{
setup_db
(
void
)
{
isc_result_t
result
;
result
=
dns_db_create
(
mctx
,
"rbt"
,
dns_rootname
,
dns_dbtype_zone
,
dns_rdataclass_in
,
0
,
NULL
,
&
db1
);
...
...
@@ -71,7 +71,7 @@ setup_db() {
}
static
void
close_db
()
{
close_db
(
void
)
{
if
(
v1
!=
NULL
)
{
dns_db_closeversion
(
db1
,
&
v1
,
ISC_FALSE
);
ATF_REQUIRE_EQ
(
v1
,
NULL
);
...
...
lib/dns/tests/dispatch_test.c
View file @
b454c031
...
...
@@ -65,7 +65,7 @@ make_dispatchset(unsigned int ndisps) {
}
static
void
teardown
()
{
teardown
(
void
)
{
if
(
dset
!=
NULL
)
dns_dispatchset_destroy
(
&
dset
);
if
(
dispatchmgr
!=
NULL
)
...
...
lib/dns/tests/dnstest.c
View file @
b454c031
...
...
@@ -76,7 +76,7 @@ static isc_logcategory_t categories[] = {
};
static
void
cleanup_managers
()
{
cleanup_managers
(
void
)
{
if
(
app_running
)
isc_app_finish
();
if
(
socketmgr
!=
NULL
)
...
...
@@ -90,7 +90,7 @@ cleanup_managers() {
}
static
isc_result_t
create_managers
()
{
create_managers
(
void
)
{
isc_result_t
result
;
#ifdef ISC_PLATFORM_USETHREADS
ncpus
=
isc_os_ncpus
();
...
...
@@ -167,7 +167,7 @@ dns_test_begin(FILE *logfile, isc_boolean_t start_managers) {
}
void
dns_test_end
()
{
dns_test_end
(
void
)
{
if
(
lctx
!=
NULL
)
isc_log_destroy
(
&
lctx
);
if
(
dst_active
)
{
...
...
@@ -243,7 +243,7 @@ dns_test_makezone(const char *name, dns_zone_t **zonep, dns_view_t *view,
}
isc_result_t
dns_test_setupzonemgr
()
{
dns_test_setupzonemgr
(
void
)
{
isc_result_t
result
;
REQUIRE
(
zonemgr
==
NULL
);
...
...
@@ -272,7 +272,7 @@ dns_test_releasezone(dns_zone_t *zone) {
}
void
dns_test_closezonemgr
()
{
dns_test_closezonemgr
(
void
)
{
REQUIRE
(
zonemgr
!=
NULL
);
dns_zonemgr_shutdown
(
zonemgr
);
...
...
lib/irs/context.c
View file @
b454c031
...
...
@@ -148,7 +148,7 @@ thread_key_mutex_init(void) {
}
static
isc_result_t
thread_key_init
()
{
thread_key_init
(
void
)
{
isc_result_t
result
;
result
=
isc_once_do
(
&
once
,
thread_key_mutex_init
);
...
...
lib/isc/app_api.c
View file @
b454c031
...
...
@@ -179,7 +179,7 @@ isc_appctx_settimermgr(isc_appctx_t *ctx, isc_timermgr_t *timermgr) {
}
isc_result_t
isc_app_start
()
{
isc_app_start
(
void
)
{
if
(
isc_bind9
)
return
(
isc__app_start
());
...
...
@@ -205,7 +205,7 @@ isc_app_run() {
}
isc_result_t
isc_app_shutdown
()
{
isc_app_shutdown
(
void
)
{
if
(
isc_bind9
)
return
(
isc__app_shutdown
());
...
...
@@ -213,7 +213,7 @@ isc_app_shutdown() {
}
isc_result_t
isc_app_reload
()
{
isc_app_reload
(
void
)
{
if
(
isc_bind9
)
return
(
isc__app_reload
());
...
...
@@ -221,7 +221,7 @@ isc_app_reload() {
}
void
isc_app_finish
()
{
isc_app_finish
(
void
)
{
if
(
!
isc_bind9
)
return
;
...
...
@@ -229,7 +229,7 @@ isc_app_finish() {
}
void
isc_app_block
()
{
isc_app_block
(
void
)
{
if
(
!
isc_bind9
)
return
;
...
...
@@ -237,7 +237,7 @@ isc_app_block() {
}
void
isc_app_unblock
()
{
isc_app_unblock
(
void
)
{
if
(
!
isc_bind9
)
return
;
...
...
lib/isc/backtrace.c
View file @
b454c031
...
...
@@ -140,7 +140,7 @@ isc_backtrace_gettrace(void **addrs, int maxaddrs, int *nframes) {
#elif defined(BACKTRACE_X86STACK)
#ifdef __x86_64__
static
unsigned
long
getrbp
()
{
getrbp
(
void
)
{
__asm
(
"movq %rbp, %rax
\n
"
);
}
#endif
...
...
lib/isc/hash.c
View file @
b454c031
...
...
@@ -275,7 +275,7 @@ isc_hash_ctxinit(isc_hash_t *hctx) {
}
void
isc_hash_init
()
{
isc_hash_init
(
void
)
{
INSIST
(
hash
!=
NULL
&&
VALID_HASH
(
hash
));
isc_hash_ctxinit
(
hash
);
...
...
@@ -338,7 +338,7 @@ isc_hash_ctxdetach(isc_hash_t **hctxp) {
}
void
isc_hash_destroy
()
{
isc_hash_destroy
(
void
)
{
unsigned
int
refs
;
INSIST
(
hash
!=
NULL
&&
VALID_HASH
(
hash
));
...
...
lib/isc/lib.c
View file @
b454c031
...
...
@@ -97,7 +97,7 @@ do_register(void) {
}
void
isc_lib_register
()
{
isc_lib_register
(
void
)
{
RUNTIME_CHECK
(
isc_once_do
(
&
register_once
,
do_register
)
==
ISC_R_SUCCESS
);
}
lib/isc/mem.c
View file @
b454c031
...
...
@@ -2266,7 +2266,7 @@ isc_mempool_getfillcount(isc_mempool_t *mpctx0) {
}
isc_result_t
isc__mem_register
()
{
isc__mem_register
(
void
)
{
return
(
isc_mem_register
(
isc_mem_create2
));
}
...
...
lib/isc/task.c
View file @
b454c031
...
...
@@ -1757,7 +1757,7 @@ isc__task_privilege(isc_task_t *task0) {
}
isc_result_t
isc__task_register
()
{
isc__task_register
(
void
)
{
return
(
isc_task_register
(
isc__taskmgr_create
));
}
...
...
lib/isc/tests/isctest.c
View file @
b454c031
...
...
@@ -63,7 +63,7 @@ static isc_logcategory_t categories[] = {
};
static
void
cleanup_managers
()
{
cleanup_managers
(
void
)
{
if
(
maintask
!=
NULL
)
isc_task_destroy
(
&
maintask
);
if
(
socketmgr
!=
NULL
)
...
...
@@ -75,7 +75,7 @@ cleanup_managers() {
}
static
isc_result_t
create_managers
()
{
create_managers
(
void
)
{
isc_result_t
result
;
#ifdef ISC_PLATFORM_USETHREADS
ncpus
=
isc_os_ncpus
();
...
...
@@ -143,7 +143,7 @@ isc_test_begin(FILE *logfile, isc_boolean_t start_managers) {
}
void
isc_test_end
()
{
isc_test_end
(
void
)
{
if
(
maintask
!=
NULL
)
isc_task_detach
(
&
maintask
);
if
(
taskmgr
!=
NULL
)
...
...
lib/isc/tests/socket_test.c
View file @
b454c031
...
...
@@ -112,7 +112,7 @@ waitfor(completion_t *completion) {
#endif
static
void
waitbody
()
{
waitbody
(
void
)
{
#ifndef ISC_PLATFORM_USETHREADS
struct
timeval
tv
;
isc_socketwait_t
*
swait
=
NULL
;
...
...
lib/isc/timer.c
View file @
b454c031
...
...
@@ -1050,7 +1050,7 @@ isc__timermgr_dispatch(isc_timermgr_t *manager0) {
#endif
/* USE_TIMER_THREAD */
isc_result_t
isc__timer_register
()
{
isc__timer_register
(
void
)
{
return
(
isc_timer_register
(
isc__timermgr_create
));
}
...
...
lib/isc/unix/app.c
View file @
b454c031
...
...
@@ -748,7 +748,7 @@ isc__app_ctxrun(isc_appctx_t *ctx0) {
}
isc_result_t
isc__app_run
()
{
isc__app_run
(
void
)
{
return
(
isc__app_ctxrun
((
isc_appctx_t
*
)
&
isc_g_appctx
));
}
...
...
@@ -825,7 +825,7 @@ isc__app_ctxshutdown(isc_appctx_t *ctx0) {
}
isc_result_t
isc__app_shutdown
()
{
isc__app_shutdown
(
void
)
{
return
(
isc__app_ctxshutdown
((
isc_appctx_t
*
)
&
isc_g_appctx
));
}
...
...
@@ -1028,7 +1028,7 @@ isc__appctx_settimermgr(isc_appctx_t *ctx0, isc_timermgr_t *timermgr) {
}
isc_result_t
isc__app_register
()
{
isc__app_register
(
void
)
{
return
(
isc_app_register
(
isc__appctx_create
));
}
...
...
lib/isc/unix/net.c
View file @
b454c031
...
...
@@ -722,13 +722,13 @@ try_dscp_v6(void) {
}
static
void
try_dscp
()
{
try_dscp
(
void
)
{
try_dscp_v4
();
try_dscp_v6
();
}
static
void
initialize_dscp
()
{
initialize_dscp
(
void
)
{
RUNTIME_CHECK
(
isc_once_do
(
&
once_dscp
,
try_dscp
)
==
ISC_R_SUCCESS
);
}
...
...
lib/isc/unix/socket.c
View file @
b454c031
...
...
@@ -6273,7 +6273,7 @@ isc__socket_gettag(isc_socket_t *socket0) {
}
isc_result_t
isc__socket_register
()
{
isc__socket_register
(
void
)
{
return
(
isc_socket_register
(
isc__socketmgr_create
));
}
...
...
lib/isc/win32/app.c
View file @
b454c031
...
...
@@ -317,7 +317,7 @@ isc__app_ctxrun(isc_appctx_t *ctx0) {
}
isc_result_t
isc__app_run
()
{
isc__app_run
(
void
)
{
return
(
isc__app_ctxrun
((
isc_appctx_t
*
)
&
isc_g_appctx
));
}
...
...
@@ -346,7 +346,7 @@ isc__app_ctxshutdown(isc_appctx_t *ctx0) {
}
isc_result_t
isc__app_shutdown
()
{
isc__app_shutdown
(
void
)
{
return
(
isc__app_ctxshutdown
((
isc_appctx_t
*
)
&
isc_g_appctx
));
}
...
...
@@ -480,7 +480,7 @@ isc__appctx_settimermgr(isc_appctx_t *ctx0, isc_timermgr_t *timermgr) {
}
isc_result_t
isc__app_register
()
{
isc__app_register
(
void
)
{
return
(
isc_app_register
(
isc__appctx_create
));
}
...
...
lib/isc/win32/net.c
View file @
b454c031
...
...
@@ -334,6 +334,6 @@ isc_net_enableipv6(void) {
}
unsigned
int
isc_net_probedscp
()
{
isc_net_probedscp
(
void
)
{
return
(
0
);
}
lib/isc/win32/ntpaths.c
View file @
b454c031
...
...
@@ -50,7 +50,7 @@ static DWORD baseLen = MAX_PATH;
static
BOOL
Initialized
=
FALSE
;
void
isc_ntpaths_init
()
{
isc_ntpaths_init
(
void
)
{
HKEY
hKey
;
BOOL
keyFound
=
TRUE
;
...
...
lib/isc/win32/socket.c
View file @
b454c031
...
...
@@ -4072,7 +4072,7 @@ error:
*/
isc_result_t
isc__socket_register
()
{
isc__socket_register
(
void
)
{
return
(
ISC_R_SUCCESS
);
}
...
...
lib/isc/win32/syslog.c
View file @
b454c031
...
...
@@ -138,7 +138,7 @@ openlog(const char *name, int flags, ...) {
* In fact if we failed then we would have nowhere to put the message
*/
void
closelog
()
{
closelog
(
void
)
{
DeregisterEventSource
(
hAppLog
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment