Open System Services Library Calls Reference Manual (G06.29+, H06.08+, J06.03+)

strncpy64(3) OSS Library Calls Reference Manual
NAME
strncpy64 - Copies a string
LIBRARY
H-series and J-series native Guardian processes: implicit libraries
H-series and J-series OSS processes: implicit libraries
SYNOPSIS
#include <string.h>
char _ptr64 *strncpy64(
char _ptr64 *s1,
const char _ptr64 *s2,
unsigned long long n);
PARAMETERS
s1 Points to a location containing first string.
s2 Points to a location containing the second of two strings referenced.
n Specifies the number of bytes to copy.
DESCRIPTION
The strncpy64( ) function copies no more than the number of bytes specified by the n parameter
from the location pointed to by the s2 parameter to the location pointed to by the s1 parameter.
Bytes following a null character are not copied.
When the location pointed to by the s2 parameter is a string whose byte length is less than the
value specified by the n parameter, null characters are appended to the s1 string until n bytes are
contained in the string.
NOTES
When operating on overlapping strings, the behavior of this function is unreliable.
RETURN VALUES
Upon successful completion, the strncpy64( ) function returns a pointer to the resulting string.
Otherwise, this function returns a null pointer.
RELATED INFORMATION
Functions: strcat64(3), strcmp64(3), strcpy64(3), strncat64(3), strncmp64(3).
6162 Hewlett-Packard Company 527187-017