X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=Client%20Applications%2Frcracki_mt%2FMemoryPool.cpp;h=77a4eabbd5aacca9bdd22776718c896ad7952084;hb=86bbf0fd5ba4e07d3279b4179fd8fc808198eaae;hp=3673446af24dcc9e89a72418d24516deff914f5f;hpb=371055825f09b5dc2ad00e5702ef4ffe18c419b0;p=freerainbowtables diff --git a/Client Applications/rcracki_mt/MemoryPool.cpp b/Client Applications/rcracki_mt/MemoryPool.cpp index 3673446..77a4eab 100644 --- a/Client Applications/rcracki_mt/MemoryPool.cpp +++ b/Client Applications/rcracki_mt/MemoryPool.cpp @@ -33,14 +33,14 @@ CMemoryPool::CMemoryPool(unsigned int bytesSaved, bool bDebug, uint64 maxMem) m_nMemSize = 0; debug = bDebug; - uint64 nAvailPhys = GetAvailPhysMemorySize(); + unsigned long nAvailPhys = GetAvailPhysMemorySize(); if ( debug ) { - #ifdef _WIN32 + #if defined(_WIN32) && !defined(__GNUC__) printf( "Debug: nAvailPhys: %I64u\n", nAvailPhys ); #else - printf( "Debug: nAvailPhys: %llu\n", nAvailPhys ); + printf( "Debug: nAvailPhys: %lu\n", nAvailPhys ); #endif printf( "Debug: bytesSaved: %d\n", bytesSaved ); } @@ -91,8 +91,8 @@ unsigned char* CMemoryPool::Allocate(unsigned int nFileLen, uint64& nAllocatedSi m_pMem = new (nothrow) unsigned char[nTargetSize]; while (m_pMem == NULL && nTargetSize >= 32 * 1024 * 1024 ) { - nTargetSize -= 16 * 1024 * 1024; - m_pMem = new (nothrow) unsigned char[nTargetSize]; + nTargetSize -= 16 * 1024 * 1024; + m_pMem = new (nothrow) unsigned char[nTargetSize]; } if (m_pMem != NULL)