"(unsigned) char *" is proper type. -fstrict-aliasing uint8_t is not character type, so is not compatible with strict aliasing. POSIX tells that "char" is 8 bit and two's complement, so it is safe to convert signed<->unsigned. #if UCHAR_MAX != 255 #error "unsigned char is expected to be 8-bit" #endif