1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

crypto: remove extraneous casts & rename rand_lin to rand_linux

This commit is contained in:
joe-conigliaro
2020-01-24 08:49:13 +11:00
committed by Alexander Medvednikov
parent dd61a22367
commit 2897bac549
8 changed files with 10 additions and 10 deletions

View File

@@ -37,7 +37,7 @@ pub fn new_cipher(key []byte) ?Cipher {
}
mut j := byte(0)
for i := 0; i < 256; i++ {
j += byte(c.s[i]) + byte(key[i%key.len])
j += byte(c.s[i]) + key[i%key.len]
tmp := c.s[i]
c.s[i] = c.s[j]
c.s[j] = tmp