Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 11115


Ignore:
Timestamp:
Feb 14, 2016, 6:08:13 PM (8 years ago)
Author:
landauf
Message:

fixed code to compile in 64bit mode

Location:
code/trunk/src
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/external/bullet/LinearMath/btAlignedAllocator.cpp

    r8351 r11115  
    6767  real = (char *)sAllocFunc(size + sizeof(void *) + (alignment-1));
    6868  if (real) {
    69     offset = (alignment - (unsigned long)(real + sizeof(void *))) & (alignment-1);
     69    offset = (alignment - (unsigned long long)(real + sizeof(void *))) & (alignment-1);
    7070    ret = (void *)((real + sizeof(void *)) + offset);
    7171    *((void **)(ret)-1) = (void *)(real);
  • code/trunk/src/external/bullet/LinearMath/btSerializer.h

    r8393 r11115  
    248248                        }
    249249                        {
    250                                 nr= (long)cp;
     250                                nr= (long long)cp;
    251251                        //      long mask=3;
    252252                                nr= ((nr+3)&~3)-nr;
     
    283283
    284284                {
    285                                 nr= (long)cp;
     285                                nr= (long long)cp;
    286286                        //      long mask=3;
    287287                                nr= ((nr+3)&~3)-nr;
  • code/trunk/src/libraries/core/Core.cc

    r11071 r11115  
    433433        unsigned int coreNr = limitToCPU - 1;
    434434        // Get the current process core mask
    435         DWORD procMask;
    436         DWORD sysMask;
     435        ULONG_PTR procMask;
     436        ULONG_PTR sysMask;
    437437#  if _MSC_VER >= 1400 && defined (_M_X64)
    438438        GetProcessAffinityMask(GetCurrentProcess(), (PDWORD_PTR)&procMask, (PDWORD_PTR)&sysMask);
  • code/trunk/src/libraries/core/GraphicsManager.cc

    r11085 r11115  
    320320        HWND hwnd;
    321321        this->renderWindow_->getCustomAttribute("WINDOW", (void*)&hwnd);
    322         LONG iconID = (LONG)LoadIcon(GetModuleHandle(nullptr), MAKEINTRESOURCE(101));
    323         SetClassLong(hwnd, GCL_HICON, iconID);
     322        LONG_PTR iconID = (LONG_PTR)LoadIcon(GetModuleHandle(nullptr), MAKEINTRESOURCE(101));
     323        SetClassLongPtr(hwnd, GCLP_HICON, iconID);
    324324#endif
    325325
  • code/trunk/src/libraries/util/SignalHandler.cc

    r11071 r11115  
    722722        // Now print information about where the fault occured
    723723        output += " at location " + SignalHandler::pointerToString(pExceptionRecord->ExceptionAddress);
    724         if ((hModule = (HMODULE) SignalHandler::getModuleBase((DWORD) pExceptionRecord->ExceptionAddress)) && GetModuleFileName(hModule, szModule, MAX_PATH))
     724        if ((hModule = (HMODULE) SignalHandler::getModuleBase(pExceptionRecord->ExceptionAddress)) && GetModuleFileName(hModule, szModule, MAX_PATH))
    725725        {
    726726            output += " in module ";
     
    748748    /// Retrieves the base address of the module that contains the specified address.
    749749    // Code from Dr. Mingw by Jos\E9 Fonseca
    750     /* static */ DWORD SignalHandler::getModuleBase(DWORD dwAddress)
     750    /* static */ PVOID SignalHandler::getModuleBase(LPCVOID dwAddress)
    751751    {
    752752        MEMORY_BASIC_INFORMATION Buffer;
    753753
    754         return VirtualQuery((LPCVOID) dwAddress, &Buffer, sizeof(Buffer)) ? (DWORD) Buffer.AllocationBase : 0;
     754        return VirtualQuery(dwAddress, &Buffer, sizeof(Buffer)) ? Buffer.AllocationBase : 0;
    755755    }
    756756
  • code/trunk/src/libraries/util/SignalHandler.h

    r11071 r11115  
    120120
    121121            static std::string getModuleName(const std::string& path);
    122             static DWORD getModuleBase(DWORD dwAddress);
     122            static PVOID getModuleBase(LPCVOID dwAddress);
    123123
    124124            template <typename T>
  • code/trunk/src/modules/overlays/GUIOverlay.cc

    r11071 r11115  
    7373        if (this->isVisible())
    7474        {
    75             const std::string& str = multi_cast<std::string>(reinterpret_cast<long>(this));
     75            const std::string& str = multi_cast<std::string>(reinterpret_cast<long long>(this));
    7676            GUIManager::getInstance().showGUIExtra(this->guiName_, str);
    7777
Note: See TracChangeset for help on using the changeset viewer.