BSTRING(3-BSD) RISC/os Reference Manual BSTRING(3-BSD)
NAME
bcopy, bcmp, bzero, ffs - bit and byte string operations
SYNOPSIS
For -systype svr3 and -systype bsd43:
bcopy(src, dst, length)
char *src, *dst;
int length;
bcmp(b1, b2, length)
char *b1, *b2;
int length;
bzero(b, length)
char *b;
int length;
ffs(i)
int i;
DESCRIPTION
The functions bcopy, bcmp, and bzero operate on variable
length strings of bytes. They do not check for null bytes
as the routines in string(3) do.
-lbsd must be linked in for any of these routines to work
with -systype svr3.
bcopy copies length bytes from string src to the string dst.
bcmp compares byte string b1 against byte string b2, return-
ing zero if they are identical, non-zero otherwise. Both
strings are assumed to be length bytes long. bcmp of length
zero bytes always returns zero.
bzero places length 0 bytes in the string b1.
ffs finds the first bit set in the argument passed it and
returns the index of that bit. Bits are numbered starting
at 1, from the right. A return value of 0 indicates the
value passed is zero.
BUGS
The bcopy routine take parameters backwards from strcpy (see
string(3C)).
ORIGIN
BSD4.3
NOTE
When these routines are used in a program which is compiled
Printed 11/19/92 Page 1
BSTRING(3-BSD) RISC/os Reference Manual BSTRING(3-BSD)
in -systype svr3, they are not resolved by libc.a. See
intro(3) for more information.
Page 2 Printed 11/19/92