aboutsummaryrefslogtreecommitdiff
path: root/src/file_reader.hpp
diff options
context:
space:
mode:
authorVitaly Novichkov <admin@wohlnet.ru>2018-06-20 19:17:01 +0300
committerVitaly Novichkov <admin@wohlnet.ru>2018-06-20 19:17:01 +0300
commita0fa0cded46bdc94293f02d4070a69bcae5478bb (patch)
treeabf2236feef7ebc8dba3d9e7fb7eaa009de95991 /src/file_reader.hpp
parent8326a355c45d1d038934264be5f00c7dc5ac33c7 (diff)
downloadlibADLMIDI-a0fa0cded46bdc94293f02d4070a69bcae5478bb.tar.gz
libADLMIDI-a0fa0cded46bdc94293f02d4070a69bcae5478bb.tar.bz2
libADLMIDI-a0fa0cded46bdc94293f02d4070a69bcae5478bb.zip
Avoid possible failure to compile for Windows
Diffstat (limited to 'src/file_reader.hpp')
-rw-r--r--src/file_reader.hpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/file_reader.hpp b/src/file_reader.hpp
index ce4307b..e0664b4 100644
--- a/src/file_reader.hpp
+++ b/src/file_reader.hpp
@@ -83,14 +83,14 @@ public:
*/
void openFile(const char *path)
{
- #if !defined(_WIN32) || defined(__WATCOMC__)
+#if !defined(_WIN32) || defined(__WATCOMC__)
m_fp = std::fopen(path, "rb");
- #else
+#else
wchar_t widePath[MAX_PATH];
int size = MultiByteToWideChar(CP_UTF8, 0, path, (int)std::strlen(path), widePath, MAX_PATH);
widePath[size] = '\0';
- fp = _wfopen(widePath, L"rb");
- #endif
+ m_fp = _wfopen(widePath, L"rb");
+#endif
m_file_name = path;
m_mp = NULL;
m_mp_size = 0;