Alexandre Julliard : user32: Replace a pointer cast by FIELD_OFFSET.

Alexandre Julliard julliard at winehq.org
Wed Oct 17 09:05:28 CDT 2007


Module: wine
Branch: master
Commit: 07bf51efbd06f147248aa6e970b0a6655111910c
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=07bf51efbd06f147248aa6e970b0a6655111910c

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Wed Oct 17 14:18:06 2007 +0200

user32: Replace a pointer cast by FIELD_OFFSET.

---

 dlls/user32/winproc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/dlls/user32/winproc.c b/dlls/user32/winproc.c
index e58d1f0..51936af 100644
--- a/dlls/user32/winproc.c
+++ b/dlls/user32/winproc.c
@@ -524,7 +524,7 @@ static LRESULT call_window_proc16( HWND16 hwnd, UINT16 msg, WPARAM16 wParam, LPA
     if (!(context.Eax = GetWindowWord( HWND_32(hwnd), GWLP_HINSTANCE ))) context.Eax = context.SegDs;
     context.SegCs = SELECTOROF(proc);
     context.Eip   = OFFSETOF(proc);
-    context.Ebp   = OFFSETOF(NtCurrentTeb()->WOW32Reserved) + (WORD)&((STACK16FRAME*)0)->bp;
+    context.Ebp   = OFFSETOF(NtCurrentTeb()->WOW32Reserved) + FIELD_OFFSET(STACK16FRAME, bp);
 
     if (lParam)
     {




More information about the wine-cvs mailing list