summaryrefslogtreecommitdiffstats
path: root/src/m_loop_counter.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/m_loop_counter.c')
-rw-r--r--src/m_loop_counter.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/src/m_loop_counter.c b/src/m_loop_counter.c
index d1d4dcf..936fa7c 100644
--- a/src/m_loop_counter.c
+++ b/src/m_loop_counter.c
@@ -28,15 +28,12 @@ char *m_counter_line_backslash(int fd,
c_gnl(fd, &counter_line, psx, msh);
else
get_next_line(fd, &counter_line);
- if (counter_line[0] != C_NUL)
- {
- l = ft_nrealloc(l,
- ft_strlen(l) + 1,
- ft_strlen(l) + ft_strlen(counter_line));
- ft_memcpy(l + ft_strlen(l) - 1,
- counter_line,
- ft_strlen(counter_line) + 1);
- }
+ l = ft_nrealloc(l,
+ ft_strlen(l) + 1,
+ ft_strlen(l) + ft_strlen(counter_line));
+ ft_memcpy(l + ft_strlen(l) - 1,
+ counter_line,
+ ft_strlen(counter_line) + 1);
ft_memdel((void*)&counter_line);
return (l);
}