[SSSD] [Patch] Cmocka unit test patch for authtok module

Jakub Hrozek jhrozek at redhat.com
Tue Jan 7 10:22:10 UTC 2014


On Wed, Dec 11, 2013 at 03:47:17PM +0545, Pallavi Jha wrote:
> Hello,
> 
> Please find the updated patch attached with this mail.
> 
> With regards
> Pallavi Kumari Jha
> Computer Science Engineering

Hi Pallavi,
there are still two compilation warnings in the code. Attached is a
patch with changes I suggest, can you check them and if you agree squash
them in your patch?
-------------- next part --------------
>From 778c8be8f15bc1652e5fc0851b4a611528709f00 Mon Sep 17 00:00:00 2001
From: Jakub Hrozek <jhrozek at redhat.com>
Date: Tue, 7 Jan 2014 11:21:13 +0100
Subject: [PATCH] Fix compilation warning in the authtok module test

---
 src/tests/cmocka/test_authtok.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/tests/cmocka/test_authtok.c b/src/tests/cmocka/test_authtok.c
index 0b1ad48e1c4cd10627f45d9ed264f477b3356408..7a497937fca51c28e446a17c6e530d56c0d688c7 100644
--- a/src/tests/cmocka/test_authtok.c
+++ b/src/tests/cmocka/test_authtok.c
@@ -147,7 +147,7 @@ static void test_sss_authtok_ccfile(void **state)
     assert_string_equal(data, pwd);
     assert_int_equal(len - 1, ret_len);
 
-    ret = sss_authtok_set_ccfile(ts->authtoken, (uint8_t *)data, len);
+    ret = sss_authtok_set_ccfile(ts->authtoken, data, len);
 
     assert_int_equal(ret, EOK);
 
@@ -158,7 +158,7 @@ static void test_sss_authtok_ccfile(void **state)
     assert_int_equal(len - 1, ret_len);
 
 
-    ret = sss_authtok_set(ts->authtoken, type, data, 0);
+    ret = sss_authtok_set(ts->authtoken, type, (uint8_t *) data, 0);
 
     assert_int_equal(ret, EOK);
     assert_int_equal(type, sss_authtok_get_type(ts->authtoken));
-- 
1.8.4.2



More information about the sssd-devel mailing list