diff options
Diffstat (limited to 'options.cpp')
-rw-r--r-- | options.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/options.cpp b/options.cpp index 72a0b77..c615cb8 100644 --- a/options.cpp +++ b/options.cpp @@ -1032,7 +1032,7 @@ static BOOL CALLBACK DlgProcLoadPublicKey(HWND hwndDlg,UINT msg,WPARAM wParam,LP { break; } - wfstream f(tmp, std::ios::in | std::ios::ate); + wfstream f(tmp, std::ios::in | std::ios::ate | std::ios::binary); delete [] tmp; if(!f.is_open()) { @@ -1041,7 +1041,7 @@ static BOOL CALLBACK DlgProcLoadPublicKey(HWND hwndDlg,UINT msg,WPARAM wParam,LP } if(f.is_open()) { - std::ifstream::pos_type size = f.tellg(); + std::wifstream::pos_type size = f.tellg(); TCHAR *tmp = new TCHAR [(std::ifstream::pos_type)size+(std::ifstream::pos_type)1]; f.seekg(0, std::ios::beg); f.read(tmp, size); |