xref: /original-bsd/lib/libc/string/swab.3 (revision 05bf53f3)
1.\" Copyright (c) 1990, 1991, 1993
2.\"	The Regents of the University of California.  All rights reserved.
3.\"
4.\" %sccs.include.redist.man%
5.\"
6.\"     @(#)swab.3	8.1 (Berkeley) 06/04/93
7.\"
8.Dd
9.Dt SWAB 3
10.Os
11.Sh NAME
12.Nm swab
13.Nd swap adjacent bytes
14.Sh SYNOPSIS
15.Fd #include <string.h>
16.Ft void
17.Fn swab "const void *src" "void *dst" "size_t len"
18.Sh DESCRIPTION
19The function
20.Fn swab
21copies
22.Fa len
23bytes from the location referenced by
24.Fa src
25to the location referenced by
26.Fa dst ,
27swapping adjacent bytes.
28.Pp
29The argument
30.Fa len
31must be even number.
32.Sh SEE ALSO
33.Xr bzero 3 ,
34.Xr memset 3
35.Sh HISTORY
36A
37.Fn swab
38function appeared in
39.At v7 .
40