Open System Services Library Calls Reference Manual (G06.29+, H06.08+, J06.03+)
strncmp64(3) OSS Library Calls Reference Manual
NAME
strncmp64 - Compares two strings
LIBRARY
H-series and J-series native Guardian processes: implicit libraries
H-series and J-series OSS processes: implicit libraries
SYNOPSIS
#include <string.h>
int strncmp64(
const 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 maximum number of bytes to compare.
DESCRIPTION
The strncmp64( ) function compares the string pointed to by the s1 parameter to the string
pointed to by the s2 parameter. The sign of a nonzero value returned by strncmp64( ) is deter-
mined by the sign of the difference between the values of the first pair of bytes (both interpreted
as unsigned char) that differ in the two compared objects. The strncmp64( ) function compares
bytes until it has compared n bytes or until it reaches a terminating null byte.
The strncmp64( ) function compares strings based on the machine collating order. It does not use
the locale-dependent sorting order.
RETURN VALUES
Upon successful completion, the strncmp64() function returns an integer whose value is greater
than, equal to, or less than 0 (zero), according to whether the s1 string is greater than, equal to, or
less than the s2 string. When a successful comparison cannot be made, this function returns a
value of 0 (zero).
RELATED INFORMATION
Functions: strcat64(3), strcmp64(3), strcpy64(3), strncat64(3), strncpy64(3).
6−160 Hewlett-Packard Company 527187-017