From 31e3dc2e75459f681480ae09641f1087096dfd69 Mon Sep 17 00:00:00 2001 From: Nayd Date: Sun, 11 Jan 2015 22:12:49 +0000 Subject: Dep/CascLib: Update to https://github.com/ladislav-zezula/CascLib/commit/5d3789af3435534c288c2145e158d422651c7fe1 Closes #13866 --- dep/CascLib/src/common/Common.cpp | 23 ++++++----------------- 1 file changed, 6 insertions(+), 17 deletions(-) (limited to 'dep/CascLib/src/common/Common.cpp') diff --git a/dep/CascLib/src/common/Common.cpp b/dep/CascLib/src/common/Common.cpp index d81c1b6fd89..74f86d44853 100644 --- a/dep/CascLib/src/common/Common.cpp +++ b/dep/CascLib/src/common/Common.cpp @@ -61,20 +61,6 @@ unsigned char AsciiToUpperTable[256] = unsigned char IntToHexChar[] = "0123456789abcdef"; -//----------------------------------------------------------------------------- -// Support for memory reallocation - -#if defined(_MSC_VER) && defined(_DEBUG) -void * DbgRealloc(void * ptr, size_t nSize) -{ - // HeapReAlloc does not support NULL as previous block - if(ptr == NULL) - return HeapAlloc(GetProcessHeap, 0, nSize); - - return HeapReAlloc(GetProcessHeap(), 0, ptr, nSize); -} -#endif - //----------------------------------------------------------------------------- // GetLastError/SetLastError support for non-Windows platform @@ -232,11 +218,14 @@ TCHAR * CombinePath(const TCHAR * szDirectory, const TCHAR * szSubDir) return szFullPath; } -void NormalizeFileName_UpperBkSlash(char * szFileName) +void NormalizeFileName_UpperBkSlash(const char * szSrcFileName, char * szTrgFileName) { + size_t i; + // Normalize the file name: ToLower + BackSlashToSlash - for(size_t i = 0; szFileName[i] != 0; i++) - szFileName[i] = AsciiToUpperTable[szFileName[i]]; + for(i = 0; szSrcFileName[i] != 0; i++) + szTrgFileName[i] = AsciiToUpperTable[szSrcFileName[i]]; + szTrgFileName[i] = 0; } void NormalizeFileName_LowerSlash(char * szFileName) -- cgit v1.2.3