Print this page
Minor markup tweaks (Sy instead of Nm).
first round of POSIX 2008 stuff
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/man/man3c/bstring.3c
+++ new/usr/src/man/man3c/bstring.3c
1 -'\" te
1 +.\" Copyright 2014 Garett D'Amore <garrett@damore.org>
2 2 .\" Copyright (c) 2002, Sun Microsystems, Inc. All Rights Reserved
3 3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 -.TH BSTRING 3C "Apr 15, 2002"
7 -.SH NAME
8 -bstring, bcopy, bcmp, bzero \- memory operations
9 -.SH SYNOPSIS
10 -.LP
11 -.nf
12 -#include <strings.h>
13 -
14 -\fBvoid\fR \fBbcopy\fR(\fBconst void *\fR\fIs1\fR, \fBvoid *\fR\fIs2\fR, \fBsize_t\fR \fIn\fR);
15 -.fi
16 -
17 -.LP
18 -.nf
19 -\fBint\fR \fBbcmp\fR(\fBconst void *\fR\fIs1\fR, \fBconst void *\fR\fIs2\fR, \fBsize_t\fR \fIn\fR);
20 -.fi
21 -
22 -.LP
23 -.nf
24 -\fBvoid\fR \fBbzero\fR(\fBvoid *\fR\fIs\fR, \fBsize_t\fR \fIn\fR);
25 -.fi
26 -
27 -.SH DESCRIPTION
28 -.sp
29 -.LP
30 -The \fBbcopy()\fR, \fBbcmp()\fR, and \fBbzero()\fR functions operate as
6 +.Dd "Jul 19, 2014"
7 +.Dt BSTRING 3C
8 +.Os
9 +.Sh NAME
10 +.Nm bstring, bcopy, bcmp, bzero
11 +.Nd memory operations
12 +.Sh SYNOPSIS
13 +.In strings.h
14 +.Ft void
15 +.Fn bcopy "const void *s1" "void *s2" "size_t n"
16 +.Ft int
17 +.Fn bcmp "const void *s1" "const void *s2" "size_t n"
18 +.Ft void
19 +.Fn bzero "void *s" "size_t n"
20 +.Sh DESCRIPTION
21 +The
22 +.Fn bcopy ,
23 +.Fn bcmp ,
24 +and
25 +.Fn bzero
26 +functions operate as
31 27 efficiently as possible on memory areas (arrays of bytes bounded by a count,
32 -not terminated by a null character). They do not check for the overflow of
33 -any receiving memory area. These functions are similar to the \fBmemcpy()\fR,
34 -\fBmemcmp()\fR, and \fBmemset()\fR functions described on the \fBmemory\fR(3C)
35 -manual page.
36 -.sp
37 -.LP
38 -The \fBbcopy()\fR function copies \fIn\fR bytes from memory area \fIs1\fR to
39 -\fIs2\fR. Copying between objects that overlap will take place correctly.
40 -.sp
41 -.LP
42 -The \fBbcmp()\fR function compares the first \fIn\fR bytes of its arguments,
43 -returning 0 if they are identical and 1 otherwise. The \fBbcmp()\fR function
44 -always returns 0 when \fIn\fR is 0.
45 -.sp
46 -.LP
47 -The \fBbzero()\fR function sets the first \fIn\fR bytes in memory area \fIs\fR
28 +not terminated by a null character). They do not check for the overflow of
29 +any receiving memory area. These functions are similar to the
30 +.Xr memcpy 3C ,
31 +.Xr memcmp 3C ,
32 +and
33 +.Xr memset 3C
34 +functions.
35 +.Lp
36 +The
37 +.Fn bcopy
38 +function copies
39 +.Fa n
40 +bytes from memory area
41 +.Fa s1
42 +to
43 +.Fa s2 .
44 +Copying between objects that overlap will take place correctly.
45 +.Lp
46 +The
47 +.Fn bcmp
48 +function compares the first
49 +.Fa n
50 +bytes of its arguments, returning 0 if they are identical and 1 otherwise. The
51 +.Fn bcmp
52 +function always returns 0 when
53 +.Fa n
54 +is 0.
55 +.Lp
56 +The
57 +.Fn bzero
58 +function sets the first
59 +.Fa n
60 +bytes in memory area
61 +.Fn s
48 62 to 0.
49 -.SH WARNINGS
50 -.sp
51 -.LP
52 -The \fBbcopy()\fR function takes parameters backwards from \fBmemcmp()\fR. See
53 -\fBmemory\fR(3C).
54 -.SH ATTRIBUTES
55 -.sp
56 -.LP
57 -See \fBattributes\fR(5) for descriptions of the following attributes:
58 -.sp
59 -
60 -.sp
61 -.TS
62 -box;
63 -c | c
64 -l | l .
65 -ATTRIBUTE TYPE ATTRIBUTE VALUE
66 -_
67 -Interface Stability Standard
68 -_
69 -MT-Level MT-Safe
70 -.TE
71 -
72 -.SH SEE ALSO
73 -.sp
74 -.LP
75 -\fBmemory\fR(3C), \fBattributes\fR(5), \fBstandards\fR(5)
63 +.Sh WARNINGS
64 +The
65 +.Fn bcopy
66 +function takes parameters backwards from
67 +.Fn memcmp .
68 +See
69 +.Xr memory 3C
70 +.Sh INTERFACE STABILITY
71 +.Sy Obsolete Standard .
72 +.Sh MT-LEVEL
73 +.Sy MT-Safe .
74 +.Sh SEE ALSO
75 +.Xr memory 3C ,
76 +.Xr standards 5
77 +.Sh STANDARDS
78 +These interfaces were removed in
79 +.St -p1003.1-2008 . The standard memory routines documented in
80 +.Xr memory 3C
81 +should be used instead.
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX