From: Peter Åstrand Date: Tue, 9 Dec 2008 12:46:47 +0000 (+0000) Subject: MinGW tweak: Mark gigantic constants as longlong. X-Git-Tag: v0.0.90~326 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=06eee26b2f666d2bcfd07fdb351e368b2b45b45f;p=tigervnc.git MinGW tweak: Mark gigantic constants as longlong. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3342 3789f03b-4d11-0410-bbf8-ca57d06f2519 --- diff --git a/win/rfb_win32/FolderManager.cxx b/win/rfb_win32/FolderManager.cxx index a2fa08d3..3ab49a1c 100644 --- a/win/rfb_win32/FolderManager.cxx +++ b/win/rfb_win32/FolderManager.cxx @@ -230,14 +230,14 @@ FolderManager::getTime70(FILETIME ftime) LARGE_INTEGER uli; uli.LowPart = ftime.dwLowDateTime; uli.HighPart = ftime.dwHighDateTime; - uli.QuadPart = (uli.QuadPart - 116444736000000000) / 10000000; + uli.QuadPart = (uli.QuadPart - 116444736000000000LL) / 10000000; return uli.LowPart; } void FolderManager::getFiletime(unsigned int time70, FILETIME *pftime) { - LONGLONG ll = Int32x32To64(time70, 10000000) + 116444736000000000; + LONGLONG ll = Int32x32To64(time70, 10000000) + 116444736000000000LL; pftime->dwLowDateTime = (DWORD) ll; pftime->dwHighDateTime = (DWORD) (ll >> 32); } @@ -276,4 +276,4 @@ FolderManager::getDirSize(char *pFullPath, DWORD64 *dirSize) *dirSize = dirFileSize64; return true; -} \ No newline at end of file +} diff --git a/win/rfb_win32/SFileTransferWin32.cxx b/win/rfb_win32/SFileTransferWin32.cxx index 0894d73b..d07da47f 100644 --- a/win/rfb_win32/SFileTransferWin32.cxx +++ b/win/rfb_win32/SFileTransferWin32.cxx @@ -116,7 +116,7 @@ SFileTransferWin32::getDirSize(char *pszName, unsigned short *pHighSize16, if (!fm.getDirSize(pszName, &dw64DirSize)) return false; - if (dw64DirSize & 0xFFFF000000000000) return false; + if (dw64DirSize & 0xFFFF000000000000LL) return false; *pHighSize16 = (unsigned short)((dw64DirSize >> 32) & 0xFFFF); *pLowSize32 = (unsigned int)(dw64DirSize & 0xFFFFFFFF);