summaryrefslogtreecommitdiffstats
path: root/vncviewer/UserDialog.cxx
diff options
context:
space:
mode:
authorPeter Åstrand <astrand@cendio.se>2011-07-14 11:25:40 +0000
committerPeter Åstrand <astrand@cendio.se>2011-07-14 11:25:40 +0000
commit8c15d12a8538b514fbaae68a5030830d332eb9b8 (patch)
tree1be97aaea7a03a1a8f834ca0a70992653d35c460 /vncviewer/UserDialog.cxx
parent903a4e85c63cd304b35d32a8d79091dc8730acd1 (diff)
downloadtigervnc-8c15d12a8538b514fbaae68a5030830d332eb9b8.tar.gz
tigervnc-8c15d12a8538b514fbaae68a5030830d332eb9b8.zip
The password file must be opened in binary mode. Otherwise, you might
get "bad obfuscated password length" errors on Windows. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4586 3789f03b-4d11-0410-bbf8-ca57d06f2519
Diffstat (limited to 'vncviewer/UserDialog.cxx')
-rw-r--r--vncviewer/UserDialog.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/vncviewer/UserDialog.cxx b/vncviewer/UserDialog.cxx
index 0ac5009a..0c2559f3 100644
--- a/vncviewer/UserDialog.cxx
+++ b/vncviewer/UserDialog.cxx
@@ -65,7 +65,7 @@ void UserDialog::getUserPasswd(char** user, char** password)
ObfuscatedPasswd obfPwd(256);
FILE* fp;
- fp = fopen(passwordFileStr.buf, "r");
+ fp = fopen(passwordFileStr.buf, "rb");
if (!fp)
throw rfb::Exception(_("Opening password file failed"));