From e481385391a25c19d82ce93fbec11a973cf82e9f Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 28 Oct 2004 12:46:59 +0000 Subject: r3322: fixed a bunch of warnings in the build, including one case where it was a real bug (This used to be commit 02d5d0f685e44bd66aff4a007f0bf34c8f915574) --- source4/libcli/auth/clikrb5.c | 2 +- source4/libcli/auth/ntlmssp_parse.c | 4 ++-- source4/libcli/auth/spnego.c | 2 +- source4/libcli/auth/spnego.h | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) (limited to 'source4/libcli/auth') diff --git a/source4/libcli/auth/clikrb5.c b/source4/libcli/auth/clikrb5.c index 78492d2352..c3ea33aaec 100644 --- a/source4/libcli/auth/clikrb5.c +++ b/source4/libcli/auth/clikrb5.c @@ -386,7 +386,7 @@ cleanup_princ: { static krb5_data kdata; - kdata.data = krb5_principal_get_comp_string(context, principal, i); + kdata.data = discard_const(krb5_principal_get_comp_string(context, principal, i)); kdata.length = strlen(kdata.data); return &kdata; } diff --git a/source4/libcli/auth/ntlmssp_parse.c b/source4/libcli/auth/ntlmssp_parse.c index 22ed783666..c36bb6a4fc 100644 --- a/source4/libcli/auth/ntlmssp_parse.c +++ b/source4/libcli/auth/ntlmssp_parse.c @@ -64,7 +64,7 @@ BOOL msrpc_gen(TALLOC_CTX *mem_ctx, DATA_BLOB *blob, case 'U': s = va_arg(ap, char *); head_size += 8; - n = push_ucs2_talloc(pointers, &pointers[i].data, s); + n = push_ucs2_talloc(pointers, (void **)&pointers[i].data, s); if (n == -1) { return False; } @@ -87,7 +87,7 @@ BOOL msrpc_gen(TALLOC_CTX *mem_ctx, DATA_BLOB *blob, n = va_arg(ap, int); intargs[i] = n; s = va_arg(ap, char *); - n = push_ucs2_talloc(pointers, &pointers[i].data, s); + n = push_ucs2_talloc(pointers, (void **)&pointers[i].data, s); if (n == -1) { return False; } diff --git a/source4/libcli/auth/spnego.c b/source4/libcli/auth/spnego.c index 85d77992fa..2779f47474 100644 --- a/source4/libcli/auth/spnego.c +++ b/source4/libcli/auth/spnego.c @@ -483,7 +483,7 @@ static NTSTATUS gensec_spnego_update(struct gensec_security *gensec_security, TA { /* The server offers a list of mechanisms */ - char *my_mechs[] = {NULL, NULL}; + const char *my_mechs[] = {NULL, NULL}; NTSTATUS nt_status = NT_STATUS_INVALID_PARAMETER; if (!in.length) { diff --git a/source4/libcli/auth/spnego.h b/source4/libcli/auth/spnego.h index 926cb7f88d..3b9d148c67 100644 --- a/source4/libcli/auth/spnego.h +++ b/source4/libcli/auth/spnego.h @@ -41,7 +41,7 @@ enum spnego_negResult { }; struct spnego_negTokenInit { - char **mechTypes; + const char **mechTypes; int reqFlags; DATA_BLOB mechToken; DATA_BLOB mechListMIC; -- cgit