1
0
mirror of https://github.com/hashcat/hashcat.git synced 2025-01-11 08:10:59 +00:00

use hc_asprintf () for PR #1451 instead of snprintf ()

This commit is contained in:
philsmd 2017-11-17 09:50:52 +01:00
parent 612a50408c
commit 425290bf2b
No known key found for this signature in database
GPG Key ID: 4F25D016D9D6A8AF

View File

@ -1036,9 +1036,9 @@ int hashes_init_stage1 (hashcat_ctx_t *hashcat_ctx)
if (parser_status < PARSER_GLOBAL_ZERO)
{
char *tmp_line_buf = (char *) malloc (HCBUFSIZ_LARGE);
char *tmp_line_buf;
snprintf (tmp_line_buf, HCBUFSIZ_LARGE, "%s", line_buf);
hc_asprintf (&tmp_line_buf, "%s", line_buf);
compress_terminal_line_length (tmp_line_buf, 38, 32);
@ -1058,9 +1058,9 @@ int hashes_init_stage1 (hashcat_ctx_t *hashcat_ctx)
if (parser_status < PARSER_GLOBAL_ZERO)
{
char *tmp_line_buf = (char *) malloc (HCBUFSIZ_LARGE);
char *tmp_line_buf;
snprintf (tmp_line_buf, HCBUFSIZ_LARGE, "%s", line_buf);
hc_asprintf (&tmp_line_buf, "%s", line_buf);
compress_terminal_line_length (tmp_line_buf, 38, 32);
@ -1082,9 +1082,9 @@ int hashes_init_stage1 (hashcat_ctx_t *hashcat_ctx)
if (parser_status < PARSER_GLOBAL_ZERO)
{
char *tmp_line_buf = (char *) malloc (HCBUFSIZ_LARGE);
char *tmp_line_buf;
snprintf (tmp_line_buf, HCBUFSIZ_LARGE, "%s", line_buf);
hc_asprintf (&tmp_line_buf, "%s", line_buf);
compress_terminal_line_length (tmp_line_buf, 38, 32);
@ -1107,9 +1107,9 @@ int hashes_init_stage1 (hashcat_ctx_t *hashcat_ctx)
if (parser_status < PARSER_GLOBAL_ZERO)
{
char *tmp_line_buf = (char *) malloc (HCBUFSIZ_LARGE);
char *tmp_line_buf;
snprintf (tmp_line_buf, HCBUFSIZ_LARGE, "%s", line_buf);
hc_asprintf (&tmp_line_buf, "%s", line_buf);
compress_terminal_line_length (tmp_line_buf, 38, 32);