-
Notifications
You must be signed in to change notification settings - Fork 0
/
ft_strmove.c
22 lines (19 loc) · 1.03 KB
/
ft_strmove.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strmove.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: sbeline <sbeline@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2016/05/14 18:46:28 by sbeline #+# #+# */
/* Updated: 2016/05/14 18:46:32 by sbeline ### ########.fr */
/* */
/* ************************************************************************** */
#include "Includes/libft.h"
void ft_strmove(char **s, int pos)
{
char *tmp;
tmp = ft_strnew(ft_strlen(*s) - pos + 1, (*s + pos));
ft_strdel(s);
*s = tmp;
}