diff options
-rw-r--r-- | brainfuck.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/brainfuck.c b/brainfuck.c index 69dae83..fb15282 100644 --- a/brainfuck.c +++ b/brainfuck.c @@ -418,17 +418,17 @@ optimize_code () } /* - * FIXME valid while we use finite integers + * FIXME valid while we use finite integers */ substr = new_code; while (NULL != (substr = strstr (substr, "[-]"))) { - strncpy (substr, "Z ", 3); /* [-] set current cell to 0 */ + memcpy (substr, "Z ", 3); /* [-] set current cell to 0 */ } substr = new_code; while (NULL != (substr = strstr (substr, "[+]"))) { - strncpy (substr, "Z ", 3); /* [-] set current cell to 0 */ + memcpy (substr, "Z ", 3); /* [-] set current cell to 0 */ } free (code); |