Mercurial > gnulib
view lib/memcpy.c @ 468:1da40035bfa2
Get new copy from FSF.
author | Jim Meyering <jim@meyering.net> |
---|---|
date | Sun, 30 Jul 1995 05:30:04 +0000 |
parents | 2a84024fa38d |
children | fd8fe79702e0 |
line wrap: on
line source
/* Copy LEN bytes starting at SRCADDR to DESTADDR. Result undefined if the source overlaps with the destination. Return DESTADDR. */ char * memcpy (destaddr, srcaddr, len) char *destaddr; const char *srcaddr; int len; { char *dest = destaddr; while (len-- > 0) *destaddr++ = *srcaddr++; return dest; }