diff options
author | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2018-03-28 16:08:30 +0200 |
---|---|---|
committer | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2018-03-28 16:41:16 +0200 |
commit | a8357b34edb23aebdb84ec6c5b4e038b4920ec4a (patch) | |
tree | c6e4148869f4893cb7b345065a574a9911f0df07 /Library/PasswordLib | |
parent | 89bbd0d2e9cbddf154dccb00d0f5c4462cdf2e49 (diff) | |
download | VeraCrypt-DCS-VeraCrypt_1.22.tar.gz VeraCrypt-DCS-VeraCrypt_1.22.zip |
AskConsolePwdInt: Use the same check for maximum allowed characters in all places. line_max parameter includes zero terminator.VeraCrypt_1.22
Diffstat (limited to 'Library/PasswordLib')
-rw-r--r-- | Library/PasswordLib/ConsolePassword.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/PasswordLib/ConsolePassword.c b/Library/PasswordLib/ConsolePassword.c index 6894b50..43e03e6 100644 --- a/Library/PasswordLib/ConsolePassword.c +++ b/Library/PasswordLib/ConsolePassword.c @@ -101,7 +101,7 @@ AskConsolePwdInt( break;
}
- if ((count >= line_max &&
+ if ((count >= (line_max - 1) &&
key.UnicodeChar != CHAR_BACKSPACE) ||
key.UnicodeChar == CHAR_NULL ||
key.UnicodeChar == CHAR_TAB ||
|