Loading...
--- Libc/Libc-1725.40.4/string/FreeBSD/memcmp.3
+++ Libc/Libc-583/string/FreeBSD/memcmp.3
@@ -13,7 +13,11 @@
.\" 2. Redistributions in binary form must reproduce the above copyright
.\" notice, this list of conditions and the following disclaimer in the
.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of the University nor the names of its contributors
+.\" 3. All advertising materials mentioning features or use of this software
+.\" must display the following acknowledgement:
+.\" This product includes software developed by the University of
+.\" California, Berkeley and its contributors.
+.\" 4. Neither the name of the University nor the names of its contributors
.\" may be used to endorse or promote products derived from this software
.\" without specific prior written permission.
.\"
@@ -30,7 +34,7 @@
.\" SUCH DAMAGE.
.\"
.\" @(#)memcmp.3 8.1 (Berkeley) 6/4/93
-.\" $FreeBSD$
+.\" $FreeBSD: src/lib/libc/string/memcmp.3,v 1.8 2001/10/01 16:09:00 ru Exp $
.\"
.Dd June 4, 1993
.Dt MEMCMP 3
@@ -43,21 +47,17 @@
.Sh SYNOPSIS
.In string.h
.Ft int
-.Fo memcmp
-.Fa "const void *s1"
-.Fa "const void *s2"
-.Fa "size_t n"
-.Fc
+.Fn memcmp "const void *b1" "const void *b2" "size_t len"
.Sh DESCRIPTION
The
.Fn memcmp
function
compares byte string
-.Fa s1
+.Fa b1
against byte string
-.Fa s2 .
+.Fa b2 .
Both strings are assumed to be
-.Fa n
+.Fa len
bytes long.
.Sh RETURN VALUES
The
@@ -65,23 +65,18 @@
function
returns zero if the two strings are identical,
otherwise returns the difference between the first two differing bytes
-(treated as
-.Vt "unsigned char"
-values, so that
+(treated as unsigned char values, so that
.Sq Li \e200
is greater than
.Sq Li \&\e0 ,
for example).
Zero-length strings are always identical.
-This behavior is not required by C and portable code should only depend on the
-sign of the returned value.
.Sh SEE ALSO
.Xr bcmp 3 ,
.Xr strcasecmp 3 ,
.Xr strcmp 3 ,
.Xr strcoll 3 ,
-.Xr strxfrm 3 ,
-.Xr wmemcmp 3
+.Xr strxfrm 3
.Sh STANDARDS
The
.Fn memcmp