Class Hierarchy   Compound List   File List   Compound Members   File Members  

string.h File Reference

string functions. More...

Functions


Detailed Description

string functions.

Author(s):
Markus L. Noga <noga@inrialpes.fr>


Function Documentation

void memcpy (void * dest, void * src, size_t size)

copy memory block from src to dest.

Parameters:
dest - destination
src - source
size - number of bytes to copy

Warning:
behaviour is undefined in case source and destination blocks overlap.

void * memset (void * s, int c, size_t n)

fill memory block with a byte value.

Parameters:
s - start
c - byte fill value
n - number of bytes to fill

void mem_clear (void * start, void * end)

set memory block [start,end[ to zero.

Parameters:
start - start
end - end (non-inclusive).
Bugs and limitations:
FIXME: seems buggy. memset() usage advised.

char * strcpy (char * dest, const char * src)

Copy null-terminated string from src to dest.

Parameters:
src - source
dest - destination
Returns:
pointer to dest

int strlen (const char * s)

Determine string length.

Parameters:
s - string
s2 - second string
Returns:
string length

int strcmp (const char * s1, const char * s2)

Compare two strings.

Parameters:
s1 - first string
s2 - second string
Returns:
<0: s1<s2, ==0: s1==s2, >0: s1>s2

legOS-0.1.7 is released under Mozilla Public License. Original code © 1998-1999 by Markus L. Noga.