From 203f2b1d543e10d91a8c616d6a47bca97f7b20bc Mon Sep 17 00:00:00 2001 From: Peter Ferrie Date: Thu, 9 Mar 2017 14:20:34 -0800 Subject: [PATCH] hp9845.cpp: fix MSVC build (nw) --- src/mame/drivers/hp9845.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mame/drivers/hp9845.cpp b/src/mame/drivers/hp9845.cpp index 7659e9887cd..4e3cd26e4f5 100644 --- a/src/mame/drivers/hp9845.cpp +++ b/src/mame/drivers/hp9845.cpp @@ -1488,9 +1488,9 @@ void hp9845ct_state::draw_line(unsigned x0 , unsigned y0 , unsigned x1 , unsigne // draw line, vector generator uses Bresenham's algorithm x = x0; y = y0; - dx = abs(x1 - x); + dx = abs((int) (x1 - x)); sx = x < x1 ? 1 : -1; // actually always 1 because of normalization - dy = abs(y1 - y); + dy = abs((int) (y1 - y)); sy = y < y1 ? 1 : -1; err = (dx > dy ? dx : -dy) / 2;