Module: wine Branch: master Commit: 153e39fc984000c1eda1820ac18b0c27e6d4c3da URL: https://source.winehq.org/git/wine.git/?a=commit;h=153e39fc984000c1eda1820ac...
Author: Chip Davis cdavis@codeweavers.com Date: Tue Mar 31 19:57:11 2020 +0430
d3d8/tests: Avoid abs() on unsigned values in compare_mode().
Mostly because Clang complains.
Signed-off-by: Chip Davis cdavis@codeweavers.com Signed-off-by: Henri Verbeet hverbeet@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/d3d8/tests/device.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/d3d8/tests/device.c b/dlls/d3d8/tests/device.c index 6bb8ab3a02..25dea77b99 100644 --- a/dlls/d3d8/tests/device.c +++ b/dlls/d3d8/tests/device.c @@ -1388,8 +1388,8 @@ static int compare_mode(const void *a, const void *b) { const struct mode *mode_a = a; const struct mode *mode_b = b; - unsigned int w = mode_a->w - mode_b->w; - unsigned int h = mode_a->h - mode_b->h; + int w = mode_a->w - mode_b->w; + int h = mode_a->h - mode_b->h; return abs(w) >= abs(h) ? -w : -h; }