diff options
author | Peter S. Mazinger <ps.m@gmx.net> | 2005-12-10 00:20:35 +0000 |
---|---|---|
committer | Peter S. Mazinger <ps.m@gmx.net> | 2005-12-10 00:20:35 +0000 |
commit | f445c58e7015240d1e68aa3d7c2cf50a298e2c2a (patch) | |
tree | 8f04b68833d8339d0ba252b5a2ec00752d0129d4 /libc/stdio | |
parent | 73130cae6071638370bf04d965f1e076c9710548 (diff) |
Do hidden fread/fwrite/fclose
Diffstat (limited to 'libc/stdio')
-rw-r--r-- | libc/stdio/fclose.c | 4 | ||||
-rw-r--r-- | libc/stdio/fread.c | 8 | ||||
-rw-r--r-- | libc/stdio/fwrite.c | 8 |
3 files changed, 13 insertions, 7 deletions
diff --git a/libc/stdio/fclose.c b/libc/stdio/fclose.c index 4df2e4229..4f5e479fe 100644 --- a/libc/stdio/fclose.c +++ b/libc/stdio/fclose.c @@ -7,7 +7,8 @@ #include "_stdio.h" -int fclose(register FILE *stream) +#undef fclose +int attribute_hidden __fclose(register FILE *stream) { int rv = 0; __STDIO_AUTO_THREADLOCK_VAR; @@ -84,3 +85,4 @@ int fclose(register FILE *stream) return rv; } +strong_alias(__fclose,fclose) diff --git a/libc/stdio/fread.c b/libc/stdio/fread.c index 42a29b067..0defb36a0 100644 --- a/libc/stdio/fread.c +++ b/libc/stdio/fread.c @@ -83,14 +83,15 @@ size_t attribute_hidden __fread_unlocked(void * __restrict ptr, size_t size, siz return 0; } -weak_alias(__fread_unlocked,fread_unlocked); +weak_alias(__fread_unlocked,fread_unlocked) #ifndef __UCLIBC_HAS_THREADS__ -weak_alias(__fread_unlocked,fread); +hidden_strong_alias(__fread_unlocked,__fread) +weak_alias(__fread_unlocked,fread) #endif #elif defined __UCLIBC_HAS_THREADS__ -size_t fread(void * __restrict ptr, size_t size, size_t nmemb, +size_t attribute_hidden __fread(void * __restrict ptr, size_t size, size_t nmemb, register FILE * __restrict stream) { size_t retval; @@ -104,5 +105,6 @@ size_t fread(void * __restrict ptr, size_t size, size_t nmemb, return retval; } +strong_alias(__fread,fread) #endif diff --git a/libc/stdio/fwrite.c b/libc/stdio/fwrite.c index 50af8f7a5..abe24fbb7 100644 --- a/libc/stdio/fwrite.c +++ b/libc/stdio/fwrite.c @@ -34,14 +34,15 @@ size_t attribute_hidden __fwrite_unlocked(const void * __restrict ptr, size_t si return 0; } -weak_alias(__fwrite_unlocked,fwrite_unlocked); +weak_alias(__fwrite_unlocked,fwrite_unlocked) #ifndef __UCLIBC_HAS_THREADS__ -weak_alias(__fwrite_unlocked,fwrite); +hidden_strong_alias(__fwrite_unlocked,__fwrite) +weak_alias(__fwrite_unlocked,fwrite) #endif #elif defined __UCLIBC_HAS_THREADS__ -size_t fwrite(const void * __restrict ptr, size_t size, +size_t attribute_hidden __fwrite(const void * __restrict ptr, size_t size, size_t nmemb, register FILE * __restrict stream) { size_t retval; @@ -55,5 +56,6 @@ size_t fwrite(const void * __restrict ptr, size_t size, return retval; } +strong_alias(__fwrite,fwrite) #endif |