strchrset renvois la place du premier char trouve

This commit is contained in:
hugodu69
2020-02-19 00:17:17 +01:00
parent bafcf928e4
commit 221f0536e3
2 changed files with 3 additions and 3 deletions

View File

@@ -17,7 +17,7 @@
#include "libft.h"
int ft_strchrset(char *s, char *set)
char *ft_strchrset(const char *s, const char *set)
{
int i;
@@ -25,7 +25,7 @@ int ft_strchrset(char *s, char *set)
while (set[i] != '\0')
{
if (ft_strchr(s, set[i]) != NULL)
return (1);
return ((char *)set + i);
i++;
}
return (0);