diff --git a/srcs/part2/ft_strmapi.c b/srcs/part2/ft_strmapi.c index 16060f2..30dcb3e 100644 --- a/srcs/part2/ft_strmapi.c +++ b/srcs/part2/ft_strmapi.c @@ -6,7 +6,7 @@ /* By: hulamy +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2019/11/25 14:01:40 by hulamy #+# #+# */ -/* Updated: 2019/11/25 14:19:43 by hulamy ### ########.fr */ +/* Updated: 2019/12/04 17:01:25 by hulamy ### ########.fr */ /* */ /* ************************************************************************** */ @@ -41,9 +41,12 @@ ** char *str; ** char touppercase(unsigned int, char); ** -** if (ac != 2) +** if (ac > 2) ** return (0); -** str = av[1]; +** if (ac == 2) +** str = strdup(av[1]); +** if (ac == 1) +** str = NULL; ** printf("%s\n",str); ** str = ft_strmapi(str, touppercase); ** printf("%s\n",str);