WORD is unsigned, so we need to transalte 0xffff into -1.
This commit is contained in:
parent
83f52d11c1
commit
13de9b3579
@ -837,6 +837,9 @@ INT WINAPI GetDeviceCaps( HDC hdc, INT cap )
|
|||||||
FIXME("(%04x,%d): unsupported DeviceCaps capability, will yield 0!\n",
|
FIXME("(%04x,%d): unsupported DeviceCaps capability, will yield 0!\n",
|
||||||
hdc,cap );
|
hdc,cap );
|
||||||
ret = *(WORD *)(((char *)dc->w.devCaps) + cap);
|
ret = *(WORD *)(((char *)dc->w.devCaps) + cap);
|
||||||
|
|
||||||
|
if ((cap == NUMCOLORS) && (ret == 0xffff))
|
||||||
|
ret = -1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user