summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2020-03-01 22:33:05 +0100
committerSébastien Helleu <flashcode@flashtux.org>2020-03-01 23:14:55 +0100
commit1882686f8a16da7037b65c7be58cd1d00807cd9c (patch)
tree3fadd507f17490db024b9be65efa6ef6441d6d2f
parent0271eacbe5c46da61c54418083b2c9cd301839ba (diff)
downloadweechat-1882686f8a16da7037b65c7be58cd1d00807cd9c.zip
script: rename variable length_hash to hash_size
-rw-r--r--src/plugins/script/script-repo.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/plugins/script/script-repo.c b/src/plugins/script/script-repo.c
index 6d218f951..fb0407263 100644
--- a/src/plugins/script/script-repo.c
+++ b/src/plugins/script/script-repo.c
@@ -756,7 +756,7 @@ script_repo_sha512sum_file (const char *filename)
struct stat st;
FILE *file;
char *data, hash[512 / 8], hash_hexa[((512 / 8) * 2) + 1];
- int length_hash;
+ int hash_size;
if (stat (filename, &st) == -1)
return NULL;
@@ -774,12 +774,12 @@ script_repo_sha512sum_file (const char *filename)
}
fclose (file);
- if (!weechat_crypto_hash (data, st.st_size, "sha512", hash, &length_hash))
+ if (!weechat_crypto_hash (data, st.st_size, "sha512", hash, &hash_size))
{
free (data);
return NULL;
}
- weechat_string_base_encode (16, hash, length_hash, hash_hexa);
+ weechat_string_base_encode (16, hash, hash_size, hash_hexa);
weechat_string_tolower (hash_hexa);
free (data);