7e1b55
From 0114d24ea160676b784ef7010c19bbacc67ceea0 Mon Sep 17 00:00:00 2001
7e1b55
From: Rob Crittenden <rcritten@redhat.com>
7e1b55
Date: Thu, 15 Jul 2021 17:52:54 -0400
7e1b55
Subject: [PATCH] ipa-getkeytab: fix compiler warnings
7e1b55
7e1b55
Make read_ipa_config and filter_keys static to avoid
7e1b55
"no previous prototype" warnings.
7e1b55
7e1b55
Use correct datatype of return value for ber_scanf to
7e1b55
correct different signedness comparision.
7e1b55
7e1b55
Fixed while working on https://pagure.io/freeipa/issue/8478
7e1b55
7e1b55
Signed-off-by: Rob Crittenden <rcritten@redhat.com>
7e1b55
Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
7e1b55
Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
7e1b55
Reviewed-By: Florence Blanc-Renaud <flo@redhat.com>
7e1b55
---
7e1b55
 client/ipa-getkeytab.c | 6 +++---
7e1b55
 1 file changed, 3 insertions(+), 3 deletions(-)
7e1b55
7e1b55
diff --git a/client/ipa-getkeytab.c b/client/ipa-getkeytab.c
7e1b55
index d3673eb05..309b3c704 100644
7e1b55
--- a/client/ipa-getkeytab.c
7e1b55
+++ b/client/ipa-getkeytab.c
7e1b55
@@ -291,7 +291,7 @@ static int ldap_sasl_interact(LDAP *ld, unsigned flags, void *priv_data, void *s
7e1b55
 	return ret;
7e1b55
 }
7e1b55
 
7e1b55
-int filter_keys(krb5_context krbctx, struct keys_container *keys,
7e1b55
+static int filter_keys(krb5_context krbctx, struct keys_container *keys,
7e1b55
                 ber_int_t *enctypes)
7e1b55
 {
7e1b55
     struct krb_key_salt *ksdata;
7e1b55
@@ -507,7 +507,7 @@ static int ldap_set_keytab(krb5_context krbctx,
7e1b55
 	BerElement *sctrl = NULL;
7e1b55
 	struct berval *control = NULL;
7e1b55
 	LDAPControl **srvctrl = NULL;
7e1b55
-	int ret;
7e1b55
+	ber_tag_t ret;
7e1b55
 	int kvno, i;
7e1b55
 	ber_tag_t rtag;
7e1b55
 	ber_int_t *encs = NULL;
7e1b55
@@ -826,7 +826,7 @@ static int config_from_file(struct ini_cfgobj *cfgctx)
7e1b55
     return 0;
7e1b55
 }
7e1b55
 
7e1b55
-int read_ipa_config(struct ipa_config **ipacfg)
7e1b55
+static int read_ipa_config(struct ipa_config **ipacfg)
7e1b55
 {
7e1b55
     struct ini_cfgobj *cfgctx = NULL;
7e1b55
     struct value_obj *obj = NULL;
7e1b55
-- 
7e1b55
2.31.1
7e1b55