commit | dc50676cce35cdba3ecba3870c3f752408d6db70 | [log] [tgz] |
---|---|---|
author | Dan Fandrich <dan@coneharvesters.com> | Sat Feb 12 22:26:57 2011 -0800 |
committer | Denys Vlasenko <vda.linux@googlemail.com> | Sun Feb 13 18:37:12 2011 +0100 |
tree | a8c7861c43f656b1013a0e57672446d63ffdb263 | |
parent | 4ed3c52ce9b3ce5604c4fa075fda374f8cd01eea [diff] [blame] |
Move stpcpy replacement function into libbb Signed-off-by: Dan Fandrich <dan@coneharvesters.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
diff --git a/libbb/platform.c b/libbb/platform.c index ccde2bf..fe7ce15 100644 --- a/libbb/platform.c +++ b/libbb/platform.c
@@ -134,3 +134,14 @@ return start; } #endif + +#ifndef HAVE_STPCPY +char* FAST_FUNC stpcpy(char *p, const char *to_add) +{ + while ((*p = *to_add) != '\0') { + p++; + to_add++; + } + return p; +} +#endif