diff options
author | Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> | 2017-05-01 08:33:47 +0100 |
---|---|---|
committer | Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> | 2017-05-05 09:49:00 +0100 |
commit | 8eb57ae3f9afdd8d911f3b2862e05cd0bb042b4e (patch) | |
tree | bfc0842653f3c61ae30a1109dac0318c62be91d6 /hw/display | |
parent | b290f3b12e30e4da7acd10662e85ae8b37d75d44 (diff) |
cg3: add explicit ram_addr_t cast to scanline page variable
Coverity warns that multiplying two 32-bit values gives a 32-bit result which
is assigned to a 64-bit variable. Add an explicit ram_addr_t cast to silence
the warning.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Diffstat (limited to 'hw/display')
-rw-r--r-- | hw/display/cg3.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/display/cg3.c b/hw/display/cg3.c index 03d9197f71..7ef8a96496 100644 --- a/hw/display/cg3.c +++ b/hw/display/cg3.c @@ -113,7 +113,7 @@ static void cg3_update_display(void *opaque) for (y = 0; y < height; y++) { int update = s->full_update; - page = y * width; + page = (ram_addr_t)y * width; update |= memory_region_get_dirty(&s->vram_mem, page, width, DIRTY_MEMORY_VGA); if (update) { |