From: Thomas Bluemel Date: Tue, 27 Dec 2005 16:19:07 +0000 (+0000) Subject: properly read the cursor hotspots from the resource X-Git-Tag: backups/expat-rbuild@40467~765 X-Git-Url: https://git.reactos.org/?p=reactos.git;a=commitdiff_plain;h=2cfbdf83cd0d8a9b4443440991fd7fa3adf8d572 properly read the cursor hotspots from the resource svn path=/trunk/; revision=20372 --- diff --git a/reactos/lib/user32/windows/icon.c b/reactos/lib/user32/windows/icon.c index 28d36ad9b55..3db757a77f0 100644 --- a/reactos/lib/user32/windows/icon.c +++ b/reactos/lib/user32/windows/icon.c @@ -246,11 +246,11 @@ CreateIconFromResourceEx( if (! fIcon) { - wXHotspot = (WORD)*pbIconBits; - pbIconBits+=2; - wYHotspot = (WORD)*pbIconBits; - pbIconBits+=2; - cbIconBits-=4; + wXHotspot = *(WORD*)pbIconBits; + pbIconBits+=sizeof(WORD); + wYHotspot = *(WORD*)pbIconBits; + pbIconBits+=sizeof(WORD); + cbIconBits-=2*sizeof(WORD); } else {