[SSSD] [PATCH] util: Fix const cast failures when building with -Werror

Lukas Slebodnik lslebodn at redhat.com
Fri Jan 10 13:18:07 UTC 2014


On (10/01/14 10:17), Jakub Hrozek wrote:
>On Fri, Jan 10, 2014 at 08:15:43AM +0100, Stef Walter wrote:
>> This results when running 'make check' with $SSS_ERROR set:
>> 
>> ../src/tests/cmocka/test_authtok.c: In function ‘test_sss_authtok_password’:
>> ../src/tests/cmocka/test_authtok.c:98:48: error: cast discards
>> ‘__attribute__((const))’ qualifier from pointer target type
>> [-Werror=cast-qual]
>>      ret = sss_authtok_set(ts->authtoken, type, (uint8_t *)data, len);
>
>Hm, I wonder why I don't see these warnings despite -Wall -Wextra in my
>CFLAGS. Anyway, the patch looks good and builds fine.
>
there weren't warnings with clang :-) this is a reason why you didn't see any.
warnings are gone with gcc.

ACK++

LS



More information about the sssd-devel mailing list