-
Notifications
You must be signed in to change notification settings - Fork 0
/
ft_bzero.c
27 lines (24 loc) · 1.12 KB
/
ft_bzero.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
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_bzero.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: ssacrist <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2019/11/05 15:44:23 by ssacrist #+# #+# */
/* Updated: 2020/01/07 13:22:31 by ssacrist ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
void ft_bzero(void *original_string, size_t how_many)
{
size_t position;
char *final_string;
final_string = (char*)original_string;
position = 0;
while (position != how_many)
{
final_string[position] = '\0';
position++;
}
}