better implementation of stpcpy for pre-Android 21 NDK
This commit is contained in:
parent
ab8709dd2e
commit
4913b0ca32
|
@ -2699,8 +2699,10 @@ int dump_cache(int fd, const unsigned char *name, int exact)
|
||||||
|
|
||||||
char *stpcpy(char *dest, char const *src)
|
char *stpcpy(char *dest, char const *src)
|
||||||
{
|
{
|
||||||
strcpy(dest, src);
|
size_t src_len = strlen(src);
|
||||||
return dest + strlen(dest);
|
return memcpy(dest, src, src_len) + src_len;
|
||||||
|
// strcpy(dest, src);
|
||||||
|
// return dest + strlen(dest);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue