[SHELL32] Fix 64 bit issues
authorTimo Kreuzer <timo.kreuzer@reactos.org>
Sun, 4 Mar 2018 15:05:00 +0000 (16:05 +0100)
committerTimo Kreuzer <timo.kreuzer@reactos.org>
Sat, 4 Aug 2018 17:19:34 +0000 (19:19 +0200)
dll/win32/shell32/folders/CDesktopFolder.cpp
dll/win32/shell32/folders/CRegFolder.cpp
dll/win32/shell32/shlfileop.cpp

index b5bb839..4105932 100644 (file)
@@ -845,7 +845,7 @@ HRESULT WINAPI CDesktopFolder::CallBack(IShellFolder *psf, HWND hwndOwner, IData
     {
         if (uMsg == DFM_INVOKECOMMAND && wParam == 0)
         {
-            if (32 >= (UINT)ShellExecuteW(hwndOwner, L"open", L"rundll32.exe shell32.dll,Control_RunDLL desk.cpl", NULL, NULL, SW_SHOWNORMAL))
+            if (32 >= (UINT_PTR)ShellExecuteW(hwndOwner, L"open", L"rundll32.exe shell32.dll,Control_RunDLL desk.cpl", NULL, NULL, SW_SHOWNORMAL))
                 return E_FAIL;
             return S_OK;
         }
index fa23312..fc8eba2 100644 (file)
@@ -41,18 +41,18 @@ HRESULT CALLBACK RegFolderContextMenuCallback(IShellFolder *psf,
 
     if (_ILIsMyComputer(apidl[0]))
     {
-        if (32 >= (UINT)ShellExecuteW(hwnd, L"open", L"rundll32.exe shell32.dll,Control_RunDLL sysdm.cpl", NULL, NULL, SW_SHOWNORMAL))
+        if (32 >= (UINT_PTR)ShellExecuteW(hwnd, L"open", L"rundll32.exe shell32.dll,Control_RunDLL sysdm.cpl", NULL, NULL, SW_SHOWNORMAL))
             hr = E_FAIL;
     }
     else if (_ILIsDesktop(apidl[0]))
     {
-        if (32 >= (UINT)ShellExecuteW(hwnd, L"open", L"rundll32.exe shell32.dll,Control_RunDLL desk.cpl", NULL, NULL, SW_SHOWNORMAL))
+        if (32 >= (UINT_PTR)ShellExecuteW(hwnd, L"open", L"rundll32.exe shell32.dll,Control_RunDLL desk.cpl", NULL, NULL, SW_SHOWNORMAL))
             hr = E_FAIL;
     }
     else if (_ILIsNetHood(apidl[0]))
     {
         // FIXME path!
-        if (32 >= (UINT)ShellExecuteW(NULL, L"open", L"explorer.exe",
+        if (32 >= (UINT_PTR)ShellExecuteW(NULL, L"open", L"explorer.exe",
                                       L"::{7007ACC7-3202-11D1-AAD2-00805FC1270E}",
                                       NULL, SW_SHOWDEFAULT))
             hr = E_FAIL;
index e07d32d..6348698 100644 (file)
@@ -1530,7 +1530,7 @@ static HRESULT delete_files(FILE_OPERATION *op, const FILE_LIST *flFrom)
     {
         fileEntry = &flFrom->feFiles[i];
 
-        if ((HANDLE)fileEntry->attributes == INVALID_HANDLE_VALUE)
+        if (fileEntry->attributes == (ULONG)-1)
         {
             // This is a windows 2003 server specific value which has been removed.
             // Later versions of windows return ERROR_FILE_NOT_FOUND.