Subversion Repositories Kolibri OS

Rev

Rev 647 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 647 Rev 6433
Line -... Line 1...
-
 
1
#include 
-
 
2
 
1
int strcspn(const char* string, const char* strCharSet)
3
size_t strcspn(const char* string, const char* strCharSet)
2
{
4
{
3
	const char* temp;
5
	const char* temp;
4
	int i;
6
	int i;
5
	i=0;
7
	i=0;
6
	while(1)
8
	while(*string)
7
	{
9
	{
8
		temp=strCharSet;
10
		temp=strCharSet;
9
		while (*temp!='\0')
11
		while (*temp!='\0')
10
		{
12
		{
11
			if (*string==*temp)
13
			if (*string==*temp)
12
				return i;
14
				return i;
13
			temp++;
15
			temp++;
14
		}
16
		}
15
		i++;string++;
17
		i++;string++;
16
	}
18
	}
-
 
19
	return i;
17
}
20
}