github to gitea

This commit is contained in:
Leo Firmin
2025-10-27 23:10:48 +01:00
parent 2fa3015af4
commit cd1882c3cc
131 changed files with 338 additions and 3018 deletions
-37
View File
@@ -1,37 +0,0 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_straddchar.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: lfirmin <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/11/08 06:02:17 by lfirmin #+# #+# */
/* Updated: 2024/11/08 06:02:17 by lfirmin ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
char *ft_straddchar(char *str, char c)
{
int i;
char *res;
if (!str)
return (NULL);
i = 0;
while (str[i])
i++;
res = (char *)malloc(sizeof(char) * (i + 2));
if (!res)
return (NULL);
i = 0;
while (str[i])
{
res[i] = str[i];
i++;
}
res[i] = c;
res[i + 1] = '\0';
return (res);
}