* ld-sparc/tlssunnopic32.rd: Adjust for .dynsym changes.
[deliverable/binutils-gdb.git] / libiberty / bcopy.c
CommitLineData
252b5132
RH
1/* bcopy -- copy memory regions of arbitary length
2
39423523 3@deftypefn Supplemental void bcopy (char *@var{in}, char *@var{out}, int @var{length})
252b5132 4
39423523
DD
5Copies @var{length} bytes from memory region @var{in} to region
6@var{out}. The use of @code{bcopy} is deprecated in new programs.
252b5132 7
39423523 8@end deftypefn
252b5132
RH
9
10*/
11
12void
13bcopy (src, dest, len)
14 register char *src, *dest;
15 int len;
16{
17 if (dest < src)
18 while (len--)
19 *dest++ = *src++;
20 else
21 {
22 char *lasts = src + (len-1);
23 char *lastd = dest + (len-1);
24 while (len--)
25 *(char *)lastd-- = *(char *)lasts--;
26 }
27}
This page took 0.250877 seconds and 4 git commands to generate.