"initializer does not fit or is out of range" warnings with Sun C compiler

Werner Koch wk at gnupg.org
Thu Jan 22 20:29:57 CET 2009


On Fri, 17 Oct 2008 21:24, gcrypt-devel at mlists.thewrittenword.com said:
> The Sun C compiler gives the following warning when compiling
> src/hmac256.c:
>
> cc -DHAVE_CONFIG_H -I. -I..    -DSTANDALONE -mr -Qn -xstrconst -xO2 -xtarget=ultra2 -xarch=v8plusa -c -o hmac256-hmac256.o `test -f 'hmac256.c' || echo './'`hmac256.c
> "hmac256.c", line 535: warning: initializer does not fit or is out of range: 220

I guess that char is signed and initializing with a value > 127 leads to
this error.  I changed the type to an unsigned char array in 1.4.4.

Thanks,

  Werner

-- 
Die Gedanken sind frei.  Auschnahme regelt ein Bundeschgesetz.




More information about the Gcrypt-devel mailing list