INtime SDK Help
memchr, wmemchr

Finds the first occurrence of a character in a buffer and stops when it finds the character or when it has checked the specified number of bytes.

#include <string.h>

void *memchr (const void *buf, int c, size_t count);

#include <wchar.h>

wchar_t *wmemchr(const wchar_t *buf, wchar_t c, size_t count);

Parameters

buf
Pointer to buffer.
c
Character to look for.
count
Number of characters to check for (in bytes for memchr, wide characters for wmemchr).

Return Values

A pointer to the first location of c in buf.
Success.
A null pointer.
Failure.

Requirements

Versions Defined in Include Link to
INtime 3.0
INtime 6.0 (for wide-character versions)
intime/rt/include/string.h
intime/rt/include/wchar.h
string.h
wchar.h
clib.lib
See Also