29 lines
1.1 KiB
C
29 lines
1.1 KiB
C
/* ************************************************************************** */
|
|
/* */
|
|
/* ::: :::::::: */
|
|
/* ft_strcat.c :+: :+: :+: */
|
|
/* +:+ +:+ +:+ */
|
|
/* By: gbrochar <marvin@42.fr> +#+ +:+ +#+ */
|
|
/* +#+#+#+#+#+ +#+ */
|
|
/* Created: 2015/11/25 16:26:53 by gbrochar #+# #+# */
|
|
/* Updated: 2016/02/29 22:19:54 by gbrochar ### ########.fr */
|
|
/* */
|
|
/* ************************************************************************** */
|
|
|
|
#include "libft.h"
|
|
|
|
char *ft_strcat(char *s1, const char *s2)
|
|
{
|
|
char *p_s1;
|
|
const char *p_s2;
|
|
|
|
p_s2 = s2;
|
|
p_s1 = s1;
|
|
while (*p_s1)
|
|
p_s1++;
|
|
while ((*p_s1++ = *p_s2++))
|
|
;
|
|
*p_s1 = '\0';
|
|
return (s1);
|
|
}
|