Skip to content

Commit

Permalink
fixes unicode compile on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
skarlsson authored and dkulp committed Dec 3, 2018
1 parent b5bec5c commit 3299a9f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lang/c++/impl/FileStream.cc
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ struct FileBufferCopyIn : public BufferCopyIn {
#ifdef _WIN32
HANDLE h_;
FileBufferCopyIn(const char* filename) :
h_(::CreateFile(filename, GENERIC_READ, 0, NULL, OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL)) {
h_(::CreateFileA(filename, GENERIC_READ, 0, NULL, OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL)) {
if (h_ == INVALID_HANDLE_VALUE) {
throw Exception(boost::format("Cannot open file: %1%") % ::GetLastError());
}
Expand Down Expand Up @@ -220,7 +220,7 @@ struct FileBufferCopyOut : public BufferCopyOut {
#ifdef _WIN32
HANDLE h_;
FileBufferCopyOut(const char* filename) :
h_(::CreateFile(filename, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL)) {
h_(::CreateFileA(filename, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL)) {
if (h_ == INVALID_HANDLE_VALUE) {
throw Exception(boost::format("Cannot open file: %1%") % ::GetLastError());
}
Expand Down

0 comments on commit 3299a9f

Please sign in to comment.