Changeset View
Changeset View
Standalone View
Standalone View
lib/libc/string/strcpy.c
- This file was copied to lib/libc/powerpc64/string/strcpy.c, lib/libc/powerpc64/string/strcpy_resolver.c.
Show All 31 Lines | |||||
#if defined(LIBC_SCCS) && !defined(lint) | #if defined(LIBC_SCCS) && !defined(lint) | ||||
static char sccsid[] = "@(#)strcpy.c 8.1 (Berkeley) 6/4/93"; | static char sccsid[] = "@(#)strcpy.c 8.1 (Berkeley) 6/4/93"; | ||||
#endif /* LIBC_SCCS and not lint */ | #endif /* LIBC_SCCS and not lint */ | ||||
#include <sys/cdefs.h> | #include <sys/cdefs.h> | ||||
__FBSDID("$FreeBSD$"); | __FBSDID("$FreeBSD$"); | ||||
#include <string.h> | #include <string.h> | ||||
#ifdef WEAK_STRCPY | |||||
__weak_reference(__strcpy, strcpy); | |||||
#endif | |||||
char * | char * | ||||
strcpy(char * __restrict to, const char * __restrict from) | #ifdef WEAK_STRCPY | ||||
__strcpy | |||||
#else | |||||
strcpy | |||||
#endif | |||||
(char * __restrict to, const char * __restrict from) | |||||
{ | { | ||||
char *save = to; | char *save = to; | ||||
for (; (*to = *from); ++from, ++to); | for (; (*to = *from); ++from, ++to); | ||||
return(save); | return(save); | ||||
} | } |