xref: /csrg-svn/lib/libc/string/memmove.c (revision 42071)
141956Sbostic /*-
241956Sbostic  * Copyright (c) 1990 The Regents of the University of California.
341956Sbostic  * All rights reserved.
441956Sbostic  *
541956Sbostic  * This code is derived from software contributed to Berkeley by
641956Sbostic  * Chris Torek.
741956Sbostic  *
841956Sbostic  * %sccs.include.redist.c%
941956Sbostic  */
1041956Sbostic 
1141956Sbostic #if defined(LIBC_SCCS) && !defined(lint)
12*42071Sbostic static char sccsid[] = "@(#)memmove.c	5.2 (Berkeley) 05/15/90";
1341956Sbostic #endif /* LIBC_SCCS and not lint */
1441956Sbostic 
1541956Sbostic #include <string.h>
1641956Sbostic #include <sys/stdc.h>
1741956Sbostic 
1841956Sbostic /*
1941956Sbostic  * Copy a block of memory, handling overlap.
2041956Sbostic  */
2141956Sbostic void *
memmove(dst,src,length)22*42071Sbostic memmove(dst, src, length)
23*42071Sbostic 	void *dst;
24*42071Sbostic 	const void *src;
2541956Sbostic 	register size_t length;
2641956Sbostic {
27*42071Sbostic 	bcopy((const char *)src, (char *)dst, length);
28*42071Sbostic 	return(dst);
2941956Sbostic }
30