Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/lib/string.c b/lib/string.c
- index 546d59711a12..5fa442145935 100644
- --- a/lib/string.c
- +++ b/lib/string.c
- @@ -883,6 +883,9 @@ void *memcpy(void *dest, const void *src, size_t count)
- char *tmp = dest;
- const char *s = src;
- + if (WARN(dest > src && dest - src < count, "Unsafe memcpy!!!"))
- + return memmove(dest, src, count);
- +
- while (count--)
- *tmp++ = *s++;
- return dest;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement