Damjan Jovanovic : winex11.drv: Don't memcpy() over the DROPFILES point just after setting it.

Alexandre Julliard julliard at wine.codeweavers.com
Fri Jul 18 14:20:23 CDT 2014


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

Author: Damjan Jovanovic <damjan.jov at gmail.com>
Date:   Thu Jul 17 21:08:12 2014 +0200

winex11.drv: Don't memcpy() over the DROPFILES point just after setting it.

---

 dlls/winex11.drv/xdnd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/winex11.drv/xdnd.c b/dlls/winex11.drv/xdnd.c
index abaf4b4..26df943 100644
--- a/dlls/winex11.drv/xdnd.c
+++ b/dlls/winex11.drv/xdnd.c
@@ -566,10 +566,10 @@ static void X11DRV_XDND_SendDropFiles(HWND hwnd)
         if (dropHandle)
         {
             DROPFILES *lpDrop = GlobalLock(dropHandle);
-            lpDrop->pt.x = XDNDxy.x;
-            lpDrop->pt.y = XDNDxy.y;
             memcpy(lpDrop, GlobalLock(current->contents), GlobalSize(current->contents));
             GlobalUnlock(current->contents);
+            lpDrop->pt.x = XDNDxy.x;
+            lpDrop->pt.y = XDNDxy.y;
             TRACE("Sending WM_DROPFILES: hWnd(0x%p) %p(%s)\n", hwnd,
                 ((char*)lpDrop) + lpDrop->pFiles, debugstr_w((WCHAR*)(((char*)lpDrop) + lpDrop->pFiles)));
             GlobalUnlock(dropHandle);




More information about the wine-cvs mailing list