ReactOS
0.4.16-dev-2104-gb84fa49
strstr.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/string/strstr.c
5
* PURPOSE: Unknown
6
* PROGRAMER: Unknown
7
* UPDATE HISTORY:
8
* 25/11/05: Added license header
9
*/
10
11
#include <precomp.h>
12
/*
13
* @implemented
14
*/
15
char
*
16
CDECL
17
strstr
(
const
char
*
s
,
const
char
*
find
)
18
{
19
char
c
, sc;
20
size_t
len
;
21
22
if
((
c
= *
find
++) != 0)
23
{
24
len
=
strlen
(
find
);
25
do
{
26
do
{
27
if
((sc = *
s
++) == 0)
28
return
0;
29
}
while
(sc !=
c
);
30
}
while
(
strncmp
(
s
,
find
,
len
) != 0);
31
s
--;
32
}
33
return
(
char
*)((
size_t
)
s
);
34
}
find
static TAGID TAGID find
Definition:
db.cpp:156
CDECL
#define CDECL
Definition:
compat.h:29
size_t
unsigned int size_t
Definition:
corecrt.h:203
strlen
_ACRTIMP size_t __cdecl strlen(const char *)
Definition:
string.c:1592
strncmp
_ACRTIMP int __cdecl strncmp(const char *, const char *, size_t)
Definition:
string.c:3330
s
GLdouble s
Definition:
gl.h:2039
c
const GLubyte * c
Definition:
glext.h:8905
len
GLenum GLsizei len
Definition:
glext.h:6722
c
#define c
Definition:
ke_i.h:80
strstr
char *CDECL strstr(const char *s, const char *find)
Definition:
strstr.c:17
sdk
lib
crt
string
strstr.c
Generated on Tue Jan 6 2026 06:19:20 for ReactOS by
1.9.6