mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-03-12 04:35:28 -07:00
douniwan5788:
This commit is contained in:
parent
28fdb04fd8
commit
50d6e4abc1
@ -144,7 +144,7 @@ static void *main_loop(void *targ) {
|
||||
nl = strrchr(script_cmd_buf, '\n');
|
||||
if (nl) *nl = '\0';
|
||||
|
||||
if ((cmd = (char*) malloc(strlen(script_cmd_buf))) != NULL)
|
||||
if ((cmd = (char*) malloc(strlen(script_cmd_buf) + 1)) != NULL)
|
||||
{
|
||||
memset(cmd, 0, strlen(script_cmd_buf));
|
||||
strcpy(cmd, script_cmd_buf);
|
||||
|
Loading…
x
Reference in New Issue
Block a user