summaryrefslogtreecommitdiff
path: root/src/lib/libc/string/memcmp.3
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libc/string/memcmp.3')
-rw-r--r--src/lib/libc/string/memcmp.316
1 files changed, 7 insertions, 9 deletions
diff --git a/src/lib/libc/string/memcmp.3 b/src/lib/libc/string/memcmp.3
index 13901c1009..db4fef364b 100644
--- a/src/lib/libc/string/memcmp.3
+++ b/src/lib/libc/string/memcmp.3
@@ -33,8 +33,7 @@
33.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 33.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
34.\" SUCH DAMAGE. 34.\" SUCH DAMAGE.
35.\" 35.\"
36.\" from: @(#)memcmp.3 5.5 (Berkeley) 6/29/91 36.\" $OpenBSD: memcmp.3,v 1.4 2000/04/21 15:24:19 aaron Exp $
37.\" $Id: memcmp.3,v 1.1.1.1 1995/10/18 08:42:21 deraadt Exp $
38.\" 37.\"
39.Dd June 29, 1991 38.Dd June 29, 1991
40.Dt MEMCMP 3 39.Dt MEMCMP 3
@@ -49,8 +48,7 @@
49.Sh DESCRIPTION 48.Sh DESCRIPTION
50The 49The
51.Fn memcmp 50.Fn memcmp
52function 51function compares byte string
53compares byte string
54.Fa b1 52.Fa b1
55against byte string 53against byte string
56.Fa b2 . 54.Fa b2 .
@@ -60,10 +58,11 @@ bytes long.
60.Sh RETURN VALUES 58.Sh RETURN VALUES
61The 59The
62.Fn memcmp 60.Fn memcmp
63function 61function returns zero if the two strings are identical,
64returns zero if the the two strings are identical,
65otherwise returns the difference between the first two differing bytes 62otherwise returns the difference between the first two differing bytes
66(treated as unsigned char values, so that 63(treated as
64.Li unsigned char
65values, so that
67.Sq Li \e200 66.Sq Li \e200
68is greater than 67is greater than
69.Sq Li \&\e0 , 68.Sq Li \&\e0 ,
@@ -78,6 +77,5 @@ Zero-length strings are always identical.
78.Sh STANDARDS 77.Sh STANDARDS
79The 78The
80.Fn memcmp 79.Fn memcmp
81function 80function conforms to
82conforms to
83.St -ansiC . 81.St -ansiC .