-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathft_strclr.c
executable file
·32 lines (28 loc) · 1.04 KB
/
ft_strclr.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strclr.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: mwilliam <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2016/11/09 20:19:05 by mwilliam #+# #+# */
/* Updated: 2016/11/30 14:43:34 by mwilliam ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
/*
** Sets every character of s to '\0'
*/
void ft_strclr(char *s)
{
char *s1;
s1 = s;
if (s1)
{
while (*s1)
{
*s1 = '\0';
s1++;
}
}
}