ReactOS  0.4.13-dev-66-gc714b7f
mbsstr.c File Reference
#include <mbstring.h>
#include <stdlib.h>
Include dependency graph for mbsstr.c:

Go to the source code of this file.

Functions

unsigned char_mbsstr (const unsigned char *src1, const unsigned char *src2)
 

Function Documentation

◆ _mbsstr()

unsigned char* _mbsstr ( const unsigned char src1,
const unsigned char src2 
)

Definition at line 7 of file mbsstr.c.

8 {
9  size_t len;
10 
11  if (src2 ==NULL || *src2 == 0)
12  return (unsigned char *)src1;
13 
14  len = _mbslen(src2);
15 
16  while(*src1)
17  {
18  if ((*src1 == *src2) && (_mbsncmp(src1,src2,len) == 0))
19  return (unsigned char *)src1;
20  src1 = (unsigned char *)_mbsinc(src1);
21  }
22  return NULL;
23 }
_Check_return_ _CRTIMP size_t __cdecl _mbslen(_In_z_ const unsigned char *_Str)
smooth NULL
Definition: ftsmooth.c:416
_Check_return_ _CRTIMP int __cdecl _mbsncmp(_In_z_ const unsigned char *_Str1, _In_z_ const unsigned char *_Str2, _In_ size_t _MaxCount)
_Check_return_ _CRTIMP unsigned char *__cdecl _mbsinc(_In_z_ const unsigned char *_Ptr)
GLenum GLsizei len
Definition: glext.h:6722