[SSSD] [PATCH] krb5 child: Use the correct type when processing OTP

Jakub Hrozek jhrozek at redhat.com
Wed Apr 3 09:33:33 UTC 2013


I'm sorry, I missed this warning because I was reviewing the patch on a
machine that ran krb5 1.10. When I compiled master on a machine with
krb5 1.11 I saw this warning:

/home/remote/jhrozek/devel/sssd/src/providers/krb5/krb5_child.c: In function ‘answer_otp’:
/home/remote/jhrozek/devel/sssd/src/providers/krb5/krb5_child.c:303:5: warning: passing argument 1 of ‘sss_authtok_get_password’ from incompatible pointer type [enabled by default]
In file included from /home/remote/jhrozek/devel/sssd/src/providers/data_provider.h:44:0,
                 from /home/remote/jhrozek/devel/sssd/src/providers/dp_backend.h:25,
                 from /home/remote/jhrozek/devel/sssd/src/providers/krb5/krb5_child.c:36:
/home/remote/jhrozek/devel/sssd/src/util/authtok.h:70:9: note: expected ‘struct sss_auth_token *’ but argument is of type ‘struct sss_auth_token **’

The attached patch fixes that.
-------------- next part --------------
>From 98acbdf5f3c46e3e783204695b22c549f317f07b Mon Sep 17 00:00:00 2001
From: Jakub Hrozek <jhrozek at redhat.com>
Date: Wed, 3 Apr 2013 11:31:58 +0200
Subject: [PATCH] krb5 child: Use the correct type when processing OTP

---
 src/providers/krb5/krb5_child.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/providers/krb5/krb5_child.c b/src/providers/krb5/krb5_child.c
index 5fdb1d20bda75a1e998e2a8627f56d834186b5a5..dd01e70baf34c80aa63559cf744ebd5cd7332f68 100644
--- a/src/providers/krb5/krb5_child.c
+++ b/src/providers/krb5/krb5_child.c
@@ -300,7 +300,7 @@ static krb5_error_code answer_otp(krb5_context ctx,
     }
 
     /* Validate our assumptions about the contents of authtok. */
-    ret = sss_authtok_get_password(&kr->pd->authtok, &pwd, &len);
+    ret = sss_authtok_get_password(kr->pd->authtok, &pwd, &len);
     if (ret != EOK)
         goto done;
 
-- 
1.8.1.4



More information about the sssd-devel mailing list