fixes Windows version of readPasswordFromStdin (setLen doesn't accept negative values anymore)
This commit is contained in:
parent
d634da775d
commit
10a7830ba2
1 changed files with 1 additions and 1 deletions
|
|
@ -94,7 +94,7 @@ when defined(Windows):
|
|||
while i < password.len:
|
||||
x = runeLenAt(password, i)
|
||||
inc i, x
|
||||
password.setLen(password.len - x)
|
||||
password.setLen(max(password.len - x, 0))
|
||||
else:
|
||||
password.add(toUTF8(c.Rune))
|
||||
stdout.write "\n"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue