Fix mingw64 build: convert from LPVOID to DWORD losses precision on 64-b...

Fix mingw64 build: convert from LPVOID to DWORD losses precision on 64-bit platforms.
Should be DWORD_PTR.