accel/translate-all: Convert a void* cast into an unsigned char* cast

Strictly speaking, as far as the standard care, performing pointer
arithmetic on a void* type is ill formed. This is a GNU extension that
allows this. Instead, just use unsigned char* which preserves the same
behavior.
This commit is contained in:
Lioncash 2019-01-28 09:14:31 -05:00
parent d020acd771
commit ce8697f978
No known key found for this signature in database
GPG key ID: 4E3C3CC1031BA9C7

View file

@ -1404,7 +1404,7 @@ TranslationBlock *tb_gen_code(CPUState *cpu,
if (unlikely(gen_code_size < 0)) { if (unlikely(gen_code_size < 0)) {
goto buffer_overflow; goto buffer_overflow;
} }
search_size = encode_search(tcg_ctx, tb, (void *)gen_code_buf + gen_code_size); search_size = encode_search(tcg_ctx, tb, (unsigned char *)gen_code_buf + gen_code_size);
if (unlikely(search_size < 0)) { if (unlikely(search_size < 0)) {
goto buffer_overflow; goto buffer_overflow;
} }