diff options
author | Stefan Metzmacher <metze@samba.org> | 2014-02-27 09:59:51 +0100 |
---|---|---|
committer | Karolin Seeger <kseeger@samba.org> | 2014-09-08 07:49:10 +0200 |
commit | 889e95889f1dc1e4247265a49fb1a2d4b5a4f316 (patch) | |
tree | efc3fc57e3e9c4475a8ddba6732cb6728ed26709 /source4 | |
parent | f23aa6faad241de9adc477be6045289ba43c97d7 (diff) | |
download | samba-889e95889f1dc1e4247265a49fb1a2d4b5a4f316.tar.gz |
s4:dlz_bind9: avoid some compiler warnings
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
(cherry picked from commit fbebe7e756e4ccd0684e94e9b1e787f98f399ccc)
Diffstat (limited to 'source4')
-rw-r--r-- | source4/dns_server/dlz_bind9.c | 6 | ||||
-rw-r--r-- | source4/dns_server/dlz_minimal.h | 2 | ||||
-rw-r--r-- | source4/torture/dns/dlz_bind9.c | 7 |
3 files changed, 8 insertions, 7 deletions
diff --git a/source4/dns_server/dlz_bind9.c b/source4/dns_server/dlz_bind9.c index c0ed8e11cbd..46c586edeb1 100644 --- a/source4/dns_server/dlz_bind9.c +++ b/source4/dns_server/dlz_bind9.c @@ -459,7 +459,7 @@ static isc_result_t b9_putnamedrr(struct dlz_bind9_data *state, parse options */ static isc_result_t parse_options(struct dlz_bind9_data *state, - unsigned int argc, char *argv[], + unsigned int argc, const char **argv, struct b9_options *options) { int opt; @@ -470,7 +470,7 @@ static isc_result_t parse_options(struct dlz_bind9_data *state, { NULL } }; - pc = poptGetContext("dlz_bind9", argc, (const char **)argv, long_options, + pc = poptGetContext("dlz_bind9", argc, argv, long_options, POPT_CONTEXT_KEEP_FIRST); while ((opt = poptGetNextOpt(pc)) != -1) { switch (opt) { @@ -564,7 +564,7 @@ static int dlz_state_debug_unregister(struct dlz_bind9_data *state) called to initialise the driver */ _PUBLIC_ isc_result_t dlz_create(const char *dlzname, - unsigned int argc, char *argv[], + unsigned int argc, const char **argv, void **dbdata, ...) { struct dlz_bind9_data *state; diff --git a/source4/dns_server/dlz_minimal.h b/source4/dns_server/dlz_minimal.h index 5262cbdaa6a..98fb34e9745 100644 --- a/source4/dns_server/dlz_minimal.h +++ b/source4/dns_server/dlz_minimal.h @@ -100,7 +100,7 @@ int dlz_version(unsigned int *flags); /* * dlz_create() is required for all DLZ external drivers. */ -isc_result_t dlz_create(const char *dlzname, unsigned int argc, char *argv[], void **dbdata, ...); +isc_result_t dlz_create(const char *dlzname, unsigned int argc, const char **argv, void **dbdata, ...); /* * dlz_destroy() is optional, and will be called when the driver is diff --git a/source4/torture/dns/dlz_bind9.c b/source4/torture/dns/dlz_bind9.c index d7d1736a6fa..88ca27cd8e6 100644 --- a/source4/torture/dns/dlz_bind9.c +++ b/source4/torture/dns/dlz_bind9.c @@ -61,7 +61,7 @@ static bool test_dlz_bind9_create(struct torture_context *tctx) NULL }; tctx_static = tctx; - torture_assert_int_equal(tctx, dlz_create("samba_dlz", 3, discard_const_p(char *, argv), &dbdata, + torture_assert_int_equal(tctx, dlz_create("samba_dlz", 3, argv, &dbdata, "log", dlz_bind9_log_wrapper, NULL), ISC_R_SUCCESS, "Failed to create samba_dlz"); @@ -109,7 +109,7 @@ static bool test_dlz_bind9_configure(struct torture_context *tctx) NULL }; tctx_static = tctx; - torture_assert_int_equal(tctx, dlz_create("samba_dlz", 3, discard_const_p(char *, argv), &dbdata, + torture_assert_int_equal(tctx, dlz_create("samba_dlz", 3, argv, &dbdata, "log", dlz_bind9_log_wrapper, "writeable_zone", dlz_bind9_writeable_zone_hook, NULL), ISC_R_SUCCESS, @@ -144,7 +144,7 @@ static bool test_dlz_bind9_gensec(struct torture_context *tctx, const char *mech NULL }; tctx_static = tctx; - torture_assert_int_equal(tctx, dlz_create("samba_dlz", 3, discard_const_p(char *, argv), &dbdata, + torture_assert_int_equal(tctx, dlz_create("samba_dlz", 3, argv, &dbdata, "log", dlz_bind9_log_wrapper, "writeable_zone", dlz_bind9_writeable_zone_hook, NULL), ISC_R_SUCCESS, @@ -216,6 +216,7 @@ static struct torture_suite *dlz_bind9_suite(TALLOC_CTX *ctx) /** * DNS torture module initialization */ +NTSTATUS torture_bind_dns_init(void); NTSTATUS torture_bind_dns_init(void) { struct torture_suite *suite; |