]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s4:kdc: Remove unnecessary casts
authorJoseph Sutton <josephsutton@catalyst.net.nz>
Wed, 9 Aug 2023 04:54:38 +0000 (16:54 +1200)
committerAndrew Bartlett <abartlet@samba.org>
Mon, 14 Aug 2023 04:57:34 +0000 (04:57 +0000)
Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
source4/kdc/db-glue.c
source4/kdc/kpasswd-service-heimdal.c
source4/kdc/kpasswd-service-mit.c

index d9fea8241a5efa2261a5480ea4a95f71801267de..41eff9c08bb9d0876fade0b35b5426dea0c8c9fa 100644 (file)
@@ -2009,7 +2009,7 @@ static krb5_error_code samba_kdc_trust_message2entry(krb5_context context,
                                                   CH_UTF16MUNGED, CH_UTF8,
                                                   password_utf16.data,
                                                   password_utf16.length,
-                                                  (void *)&password_utf8.data,
+                                                  &password_utf8.data,
                                                   &password_utf8.length);
                        if (!ok) {
                                krb5_clear_error_message(context);
index 340bc67fd8a980c658b735805111b7cff712ec32..b4709de3e5488a31c5004f784a9d8b39555b67c9 100644 (file)
@@ -136,9 +136,9 @@ static krb5_error_code kpasswd_set_password(struct kdc_server *kdc,
                                          lpcfg_iconv_handle(kdc->task->lp_ctx),
                                          CH_UTF8,
                                          CH_UTF16,
-                                         (const char *)chpw.newpasswd.data,
+                                         chpw.newpasswd.data,
                                          chpw.newpasswd.length,
-                                         (void **)&password.data,
+                                         &password.data,
                                          &password.length);
        if (!ok) {
                free_ChangePasswdDataMS(&chpw);
@@ -288,9 +288,9 @@ krb5_error_code kpasswd_handle_request(struct kdc_server *kdc,
                                                  lpcfg_iconv_handle(kdc->task->lp_ctx),
                                                  CH_UTF8,
                                                  CH_UTF16,
-                                                 (const char *)decoded_data->data,
+                                                 decoded_data->data,
                                                  decoded_data->length,
-                                                 (void **)&password.data,
+                                                 &password.data,
                                                  &password.length);
                if (!ok) {
                        *error_string = "String conversion failed!";
index fe420f94cd10295042e73434843f6bccf79a8dad..4c7e8711c3ea7b487848a0c2c9ad35b5d2b38aba 100644 (file)
@@ -211,7 +211,7 @@ static krb5_error_code kpasswd_set_password(struct kdc_server *kdc,
                                          CH_UTF16,
                                          clear_data.data,
                                          clear_data.length,
-                                         (void **)&password.data,
+                                         &password.data,
                                          &password.length);
        if (k_clear_data != NULL) {
                krb5_free_data(context, k_clear_data);
@@ -367,9 +367,9 @@ krb5_error_code kpasswd_handle_request(struct kdc_server *kdc,
                                                  lpcfg_iconv_handle(kdc->task->lp_ctx),
                                                  CH_UTF8,
                                                  CH_UTF16,
-                                                 (const char *)decoded_data->data,
+                                                 decoded_data->data,
                                                  decoded_data->length,
-                                                 (void **)&password.data,
+                                                 &password.data,
                                                  &password.length);
                if (!ok) {
                        *error_string = "String conversion failed!";