repo.or.cz
/
maemo-rb.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
FS#12756 by Marek Salaba - update Czech translation
[maemo-rb.git]
/
apps
/
plugins
/
mikmod
/
strstr.c
blob
c2cf97ecde72ebe0fd6cc88fb320b13ff38e0621
1
#ifdef HAVE_CONFIG_H
2
#include
"config.h"
3
#endif
4
5
#include <string.h>
6
7
#include
"mikmod_supp.h"
8
9
char
*
strstr
(
const char
*
haystack
,
const char
*
needle
)
10
{
11
const char
*
scan
;
12
size_t
len
;
13
char
firstc
;
14
15
firstc
= *
needle
;
16
len
=
strlen
(
needle
);
17
for
(
scan
=
haystack
; *
scan
!=
firstc
||
strncmp
(
scan
,
needle
,
len
); )
18
if
(!*
scan
++)
19
return
NULL
;
20
return
(
char
*)
scan
;
21
}