diff options
author | Pierre Ossman <ossman@cendio.se> | 2024-08-30 16:09:38 +0200 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2024-08-30 16:09:38 +0200 |
commit | 49a087e8f8ecafe950a86a71ae6657d6cac8ea77 (patch) | |
tree | 6f9250580b5d638c870924132632b196af0d7b84 | |
parent | 1b0387a36cf5f22a34b955d9c3f7ff0860e7467c (diff) | |
download | tigervnc-49a087e8f8ecafe950a86a71ae6657d6cac8ea77.tar.gz tigervnc-49a087e8f8ecafe950a86a71ae6657d6cac8ea77.zip |
Only read first password from file
Read just the first password and ignore anything else in the password
file. This allows you to reuse a password file from the server that also
includes a view-only password.
This fixes a regression introduced in b99daad.
-rw-r--r-- | vncviewer/UserDialog.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/vncviewer/UserDialog.cxx b/vncviewer/UserDialog.cxx index 901503c6..13821a9c 100644 --- a/vncviewer/UserDialog.cxx +++ b/vncviewer/UserDialog.cxx @@ -109,7 +109,7 @@ void UserDialog::getUserPasswd(bool secure_, std::string* user, } if (!user && passwordFileName[0]) { - std::vector<uint8_t> obfPwd(256); + std::vector<uint8_t> obfPwd(8); FILE* fp; fp = fopen(passwordFileName, "rb"); |