summaryrefslogtreecommitdiff
path: root/shell/qa
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2017-09-27 14:20:25 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2017-09-28 08:55:04 +0200
commite80aef4e032f08ef0c4cfbb028bf83b81002f112 (patch)
treeabb1d7e2ae7f46623d2769b5820e716ad063b4eb /shell/qa
parent09917566b6ce86ea65a246f2055b5d1f41df4e76 (diff)
shell: use Unicode on Windows
Change-Id: I9f7962db320f8832879ba327108425a7592b4b77 Reviewed-on: https://gerrit.libreoffice.org/42885 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'shell/qa')
-rw-r--r--shell/qa/zip/ziptest.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/shell/qa/zip/ziptest.cxx b/shell/qa/zip/ziptest.cxx
index 2bcfef30c84e..f554e6da71d0 100644
--- a/shell/qa/zip/ziptest.cxx
+++ b/shell/qa/zip/ziptest.cxx
@@ -42,7 +42,7 @@ using namespace std;
class Test : public CppUnit::TestFixture
{
private:
- string documentName;
+ wstring documentName;
LPSTREAM pStream;
public:
Test();
@@ -66,16 +66,16 @@ CPPUNIT_TEST_SUITE_REGISTRATION(Test);
Test::Test() : documentName(), pStream(nullptr)
{
- const char* pSrcRoot = getenv( "SRC_ROOT" );
+ const wchar_t* pSrcRoot = _wgetenv(L"SRC_ROOT");
if (pSrcRoot)
{
documentName.append(pSrcRoot);
- documentName.append("/");
+ documentName.append(L"/");
}
- documentName.append("shell/qa/zip/simpledocument.odt");
+ documentName.append(L"shell/qa/zip/simpledocument.odt");
// Create an IStream pointer from the file
- HANDLE hFile = CreateFileA(documentName.c_str(), GENERIC_READ, 0, nullptr, OPEN_EXISTING, 0, nullptr);
+ HANDLE hFile = CreateFileW(documentName.c_str(), GENERIC_READ, 0, nullptr, OPEN_EXISTING, 0, nullptr);
DWORD dwFileSize = GetFileSize(hFile, nullptr);
HGLOBAL hGlobal = GlobalAlloc(GMEM_MOVEABLE, dwFileSize);