Replace with `(unsigned char *) malloc(sizeof(char) *size);` ?