diff options
| author | Charles <sircharlesaze@gmail.com> | 2019-11-20 04:04:55 +0100 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2019-11-20 04:04:55 +0100 |
| commit | 9901cd05849fa0ef396f09f57b07807ebd96ca32 (patch) | |
| tree | f2dd9c191512bfc11c994e578291cccf270de787 /ft_strchr.c | |
| parent | a983b06df18647cf63fadad5b36f472e06f1075f (diff) | |
| download | libft-9901cd05849fa0ef396f09f57b07807ebd96ca32.tar.gz libft-9901cd05849fa0ef396f09f57b07807ebd96ca32.tar.bz2 libft-9901cd05849fa0ef396f09f57b07807ebd96ca32.zip | |
refactored everything
Diffstat (limited to 'ft_strchr.c')
| -rw-r--r-- | ft_strchr.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ft_strchr.c b/ft_strchr.c index 45eecdd..0ae161b 100644 --- a/ft_strchr.c +++ b/ft_strchr.c @@ -6,11 +6,11 @@ /* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2019/10/07 10:14:47 by cacharle #+# #+# */ -/* Updated: 2019/10/20 13:10:19 by cacharle ### ########.fr */ +/* Updated: 2019/11/20 04:02:02 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ -#include <stdlib.h> +#include "libft.h" char *ft_strchr(const char *s, int c) { @@ -20,7 +20,7 @@ char *ft_strchr(const char *s, int c) return ((char*)s); s++; } - if ((char)c == 0) + if ((char)c == '\0') return ((char*)s); return (NULL); } |
