From e463ba47a83183e7fb45c9981dbe9ccbeb4c1e1b Mon Sep 17 00:00:00 2001 From: Symeon Huang Date: Thu, 27 Nov 2014 11:02:20 +0000 Subject: [PATCH] code clean. salt is a duplicate of i --- src/encrypt.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/encrypt.c b/src/encrypt.c index f16b7046..8b70a3bc 100644 --- a/src/encrypt.c +++ b/src/encrypt.c @@ -246,7 +246,6 @@ unsigned char *enc_md5(const unsigned char *d, size_t n, unsigned char *md) void enc_table_init(const char *pass) { uint32_t i; - uint32_t salt; uint64_t key = 0; uint8_t *digest; @@ -263,8 +262,7 @@ void enc_table_init(const char *pass) enc_table[i] = i; } for (i = 1; i < 1024; ++i) { - salt = i; - merge_sort(enc_table, 256, salt, key); + merge_sort(enc_table, 256, i, key); } for (i = 0; i < 256; ++i) { // gen decrypt table from encrypt table