aboutsummaryrefslogtreecommitdiff
path: root/ft_strstr.c
diff options
context:
space:
mode:
authorCabergs Charles <cacharle@w-r4-p5.s19.be>2019-10-07 11:35:51 +0200
committerCabergs Charles <cacharle@w-r4-p5.s19.be>2019-10-07 11:35:51 +0200
commit10b4feb67c8af2b099dabd66f948b02e180bae0d (patch)
treee97d3d4701a79ac2087534dd350225e556127a76 /ft_strstr.c
parent9a2b208985ac7d4644c718ada74770b98eeb4598 (diff)
downloadlibft-10b4feb67c8af2b099dabd66f948b02e180bae0d.tar.gz
libft-10b4feb67c8af2b099dabd66f948b02e180bae0d.tar.bz2
libft-10b4feb67c8af2b099dabd66f948b02e180bae0d.zip
Normed everything
Created a few dummy functions to resolve functions having more than 25 lines.
Diffstat (limited to 'ft_strstr.c')
-rw-r--r--ft_strstr.c20
1 files changed, 16 insertions, 4 deletions
diff --git a/ft_strstr.c b/ft_strstr.c
index 0209de4..f71423f 100644
--- a/ft_strstr.c
+++ b/ft_strstr.c
@@ -1,13 +1,25 @@
+/* ************************************************************************** */
+/* */
+/* ::: :::::::: */
+/* ft_strstr.c :+: :+: :+: */
+/* +:+ +:+ +:+ */
+/* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */
+/* +#+#+#+#+#+ +#+ */
+/* Created: 2019/10/07 10:15:29 by cacharle #+# #+# */
+/* Updated: 2019/10/07 10:21:49 by cacharle ### ########.fr */
+/* */
+/* ************************************************************************** */
+
#include <stdlib.h>
#include <string.h>
#include "libft.h"
-char *ft_strstr(const char *haystack, const char *needle)
+char *ft_strstr(const char *haystack, const char *needle)
{
- size_t i;
- char *cursor;
+ size_t i;
+ char *cursor;
- cursor = (char*)haystack;
+ cursor = (char*)haystack;
if (!ft_strlen(needle))
return (cursor);
while (*cursor)