diff options
author | salad <fmoenne-@student.le-101.fr> | 2020-12-16 13:10:11 +0100 |
---|---|---|
committer | salad <fmoenne-@student.le-101.fr> | 2020-12-16 13:10:11 +0100 |
commit | 711bc9edbd9646900fc7e00e7b3457c2070ac31f (patch) | |
tree | 2b173316fcea1f8609fc9494dadce17588f248b4 /src/c_utils.c | |
parent | norm tobecontinued2 (diff) | |
download | 42-minishell-711bc9edbd9646900fc7e00e7b3457c2070ac31f.tar.gz 42-minishell-711bc9edbd9646900fc7e00e7b3457c2070ac31f.tar.bz2 42-minishell-711bc9edbd9646900fc7e00e7b3457c2070ac31f.tar.xz 42-minishell-711bc9edbd9646900fc7e00e7b3457c2070ac31f.tar.zst 42-minishell-711bc9edbd9646900fc7e00e7b3457c2070ac31f.zip |
qwe
Diffstat (limited to '')
-rw-r--r-- | src/c_utils.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/c_utils.c b/src/c_utils.c index 10013d7..1fff5a1 100644 --- a/src/c_utils.c +++ b/src/c_utils.c @@ -86,7 +86,7 @@ void i = -1; j = 0; - len = (ft_strlen(*line) + 2); + len = (*line != NULL) ? (ft_strlen(*line) + 2) : 2; if (!(dst = (char*)ft_calloc(sizeof(char), len))) return ; while (++i < (int)len) |