Commit bd44f104 authored by Alexandre Julliard's avatar Alexandre Julliard

winex11: Make sure we create valid bitmaps even for a 1x1 mask.

parent 3bbb208f
......@@ -1161,7 +1161,7 @@ static Cursor create_cursor( HANDLE handle )
#endif
GetObjectW( info.hbmMask, sizeof(bm), &bm );
if (!info.hbmColor) bm.bmHeight /= 2;
if (!info.hbmColor) bm.bmHeight = max( 1, bm.bmHeight / 2 );
/* make sure hotspot is valid */
if (info.xHotspot >= bm.bmWidth || info.yHotspot >= bm.bmHeight)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment