From 13de9b3579187458dce0424f3c5545acab5f07ec Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Tue, 26 Sep 2000 22:45:05 +0000 Subject: [PATCH] WORD is unsigned, so we need to transalte 0xffff into -1. --- objects/dc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/objects/dc.c b/objects/dc.c index 5e978b4b183..a69c7cf94c7 100644 --- a/objects/dc.c +++ b/objects/dc.c @@ -837,6 +837,9 @@ INT WINAPI GetDeviceCaps( HDC hdc, INT cap ) FIXME("(%04x,%d): unsupported DeviceCaps capability, will yield 0!\n", hdc,cap ); ret = *(WORD *)(((char *)dc->w.devCaps) + cap); + + if ((cap == NUMCOLORS) && (ret == 0xffff)) + ret = -1; break; }