Guardian Native C Library Calls Reference Manual (G06.28+, H06.04+)

Guardian Native C Library Calls (j - m) memset(3)
NAME
memset - Sets characters in memory
LIBRARY
G-series native Guardian processes: $SYSTEM.SYSnn.ZCRESRL
G-series native OSS processes: /G/system/sysnn/zcresrl
H-series native Guardian processes: $SYSTEM.ZDLLnnn.ZCREDLL
H-series OSS processes: /G/system/zdllnnn/zcredll
SYNOPSIS
#include <string.h>
void *memset(
void *s,
int c,
size_t n);
PARAMETERS
s Points to the location of a string.
c Species a byte for which c is the target of the copy.
n Species the number of bytes to copy.
DESCRIPTION
The memset() function operates on strings in memory areas. A memory area is a group of con-
tiguous bytes bound by a count and not terminated by a null character. This memory function
does not check for overow of the receiving memory area.
The memset() function copies the value of the byte specied by the c parameter, which is con-
verted to an unsigned char, into each of the rst n locations of the string pointed to by the s
parameter.
RETURN VALUES
The memset() function returns the string pointed to by the s parameter.
RELATED INFORMATION
Functions: memccpy(3), memchr(3), memcmp(3), memcpy(3), memmove(3), strcat(3).
527192-005 Hewlett-Packard Company 453