diff options
Diffstat (limited to 'libc/stdio/_fwrite.c')
-rw-r--r-- | libc/stdio/_fwrite.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/libc/stdio/_fwrite.c b/libc/stdio/_fwrite.c index d9d0bc2a8..600b15e6d 100644 --- a/libc/stdio/_fwrite.c +++ b/libc/stdio/_fwrite.c @@ -5,6 +5,9 @@ * Dedicated to Toni. See uClibc/DEDICATION.mjn3 for details. */ +#define memrchr __memrchr +#define memchr __memchr + #include "_stdio.h" #ifdef __STDIO_BUFFERS @@ -32,7 +35,7 @@ size_t attribute_hidden __stdio_fwrite(const unsigned char * __restrict buffer, if (pending > bytes) { pending = bytes; } - memcpy(stream->__bufpos, buffer, pending); + __memcpy(stream->__bufpos, buffer, pending); stream->__bufpos += pending; __STDIO_STREAM_VALIDATE(stream); return bytes; @@ -40,7 +43,7 @@ size_t attribute_hidden __stdio_fwrite(const unsigned char * __restrict buffer, /* RETRY: */ if (bytes <= __STDIO_STREAM_BUFFER_WAVAIL(stream)) { - memcpy(stream->__bufpos, buffer, bytes); + __memcpy(stream->__bufpos, buffer, bytes); stream->__bufpos += bytes; if (__STDIO_STREAM_IS_LBF(stream) && memrchr(buffer, '\n', bytes) /* Search backwards. */ |