diff options
author | Daniel Wilhelm <daniel@wili.li> | 2014-04-18 17:11:56 +0200 |
---|---|---|
committer | Daniel Wilhelm <daniel@wili.li> | 2014-04-18 17:11:56 +0200 |
commit | 98ecf620f7de377dc8ae9ad7fbd1e3b24477e138 (patch) | |
tree | faadc6d8822c20cd3bc6f50b2a98e6c580585949 /shared/zstring.cpp | |
parent | 3.16 (diff) | |
download | FreeFileSync-98ecf620f7de377dc8ae9ad7fbd1e3b24477e138.tar.gz FreeFileSync-98ecf620f7de377dc8ae9ad7fbd1e3b24477e138.tar.bz2 FreeFileSync-98ecf620f7de377dc8ae9ad7fbd1e3b24477e138.zip |
3.17
Diffstat (limited to 'shared/zstring.cpp')
-rw-r--r-- | shared/zstring.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/shared/zstring.cpp b/shared/zstring.cpp index 6440c9af..2955ec3e 100644 --- a/shared/zstring.cpp +++ b/shared/zstring.cpp @@ -12,7 +12,6 @@ #undef min #undef max #include "dll_loader.h" -#include <boost/scoped_array.hpp> #endif //FFS_WIN #ifndef NDEBUG @@ -161,16 +160,16 @@ int z_impl::compareFilenamesWin(const wchar_t* a, const wchar_t* b, size_t sizeA } else //use freestore { - boost::scoped_array<wchar_t> bufferA(new wchar_t[minSize]); - boost::scoped_array<wchar_t> bufferB(new wchar_t[minSize]); + std::vector<wchar_t> bufferA(minSize); + std::vector<wchar_t> bufferB(minSize); - if (::LCMapString(ZSTRING_INVARIANT_LOCALE, LCMAP_UPPERCASE, a, static_cast<int>(minSize), bufferA.get(), static_cast<int>(minSize)) == 0) + if (::LCMapString(ZSTRING_INVARIANT_LOCALE, LCMAP_UPPERCASE, a, static_cast<int>(minSize), &bufferA[0], static_cast<int>(minSize)) == 0) throw std::runtime_error("Error comparing strings! (LCMapString: FS)"); - if (::LCMapString(ZSTRING_INVARIANT_LOCALE, LCMAP_UPPERCASE, b, static_cast<int>(minSize), bufferB.get(), static_cast<int>(minSize)) == 0) + if (::LCMapString(ZSTRING_INVARIANT_LOCALE, LCMAP_UPPERCASE, b, static_cast<int>(minSize), &bufferB[0], static_cast<int>(minSize)) == 0) throw std::runtime_error("Error comparing strings! (LCMapString: FS)"); - rv = ::wmemcmp(bufferA.get(), bufferB.get(), minSize); + rv = ::wmemcmp(&bufferA[0], &bufferB[0], minSize); } return rv == 0 ? |