[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#744279: Conflicting declarations of variables (signed vs. unsigned char)



Package: bibtool
Version: 2.55+ds-2
Usertags: goto-cc

While compiling the package using our research compiler infrastructure it became
apparent that the following declarations are conflicting:

http://sources.debian.net/src/bibtool/2.55%2Bds-2/include/bibtool/type.h?hl=318,327,336,341,342,343#L318

Observe that the definition with internal linkage is for unsigned char, whereas
all three external ones are plain "char." Not only do Debian's platforms vary in
terms of signedness of char (so this will be consistent on some, but not on
others), but also this is worrying if ever any unicode characters (with a
character code beyond 127) are to be considered. Furthermore the compiler may
make various inconsistent assumptions, possibly causing undefined behaviour.

It seems a full code review is due with respect to char vs. unsigned char, as
this appears to get mixed.

Best,
Michael

Attachment: pgpSba0UZOIxj.pgp
Description: PGP signature


Reply to: