ReactOS 0.4.16-dev-300-g2aadf2e
mbsspn.c
Go to the documentation of this file.
1/*
2 * COPYRIGHT: See COPYING in the top level directory
3 * PROJECT: ReactOS system libraries
4 * FILE: lib/sdk/crt/mbstring/mbsspn.c
5 * PURPOSE:
6 * PROGRAMER:
7 * UPDATE HISTORY:
8 * 05/30/08: Samuel Serapion adapted from PROJECT C Library
9 *
10 */
11
12#include <precomp.h>
13#include <mbstring.h>
14
15/*
16 * @implemented
17 */
18size_t _mbsspn (const unsigned char *str1, const unsigned char *str2)
19{
20 int c;
21 const unsigned char *save = str1;
22
23 while ((c = _mbsnextc (str1))) {
24
25 if (_mbschr (str2, c) == 0)
26 break;
27
28 str1 = _mbsinc ((unsigned char *) str1);
29
30 }
31
32 return str1 - save;
33}
const GLubyte * c
Definition: glext.h:8905
_Check_return_ _CRTIMP unsigned int __cdecl _mbsnextc(_In_z_ const unsigned char *_Str)
_Check_return_ _CRTIMP _CONST_RETURN unsigned char *__cdecl _mbschr(_In_z_ const unsigned char *_Str, _In_ unsigned int _Ch)
_Check_return_ _CRTIMP unsigned char *__cdecl _mbsinc(_In_z_ const unsigned char *_Ptr)
#define c
Definition: ke_i.h:80
size_t _mbsspn(const unsigned char *str1, const unsigned char *str2)
Definition: mbsspn.c:18