Commit f68808c7 authored by Richard Henderson's avatar Richard Henderson
Browse files

translate-all: Avoid -Werror=switch-bool



gcc 5.3.0 diagnoses

translate-all.c: In function ‘alloc_code_gen_buffer’:
translate-all.c:756:17: error: switch condition has boolean value
         switch (buf2 != MAP_FAILED) {
                 ^

Signed-off-by: default avatarRichard Henderson <rth@twiddle.net>
parent f0d70331
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -753,7 +753,7 @@ static inline void *alloc_code_gen_buffer(void)
        size_t size2;
        void *buf2 = mmap(NULL, size + qemu_real_host_page_size,
                          PROT_NONE, flags, -1, 0);
        switch (buf2 != MAP_FAILED) {
        switch ((int)(buf2 != MAP_FAILED)) {
        case 1:
            if (!cross_256mb(buf2, size)) {
                /* Success!  Use the new buffer.  */