aboutsummaryrefslogtreecommitdiff
path: root/smash/env.c
diff options
context:
space:
mode:
Diffstat (limited to 'smash/env.c')
-rw-r--r--smash/env.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/smash/env.c b/smash/env.c
index 69e5e68..e14dba1 100644
--- a/smash/env.c
+++ b/smash/env.c
@@ -54,6 +54,7 @@ char* new_line_and_replace_vars(const char *line, u64 n)
}
replaced = malloc(size + 1);
+ clear_buf(replaced, size + 1);
int line_pos = 0;
for (int i = 0; i < size && line[line_pos]; ++i) {