1
0
mirror of https://github.com/hashcat/hashcat.git synced 2024-11-22 16:18:09 +00:00

Simplify code in check_hash()

This commit is contained in:
unix-ninja 2018-10-22 08:02:57 -04:00
parent cef3c1cb06
commit 1809794299

View File

@ -284,8 +284,7 @@ void check_hash (hashcat_ctx_t *hashcat_ctx, hc_device_param_t *device_param, pl
u8 *temp_ptr = (u8 *) temp_buf;
// encode our plain
base32_encode (int_to_base32, (const u8 *) plain_ptr, plain_len, (u8 *) temp_buf);
plain_len = strlen ((const char *) temp_buf);
plain_len = base32_encode (int_to_base32, (const u8 *) plain_ptr, plain_len, (u8 *) temp_buf);
// copy the base32 content into our plain buffer
strncpy ((char *) plain_ptr, (char *) temp_ptr, sizeof (plain_buf));