about summary refs log tree commit diff
path: root/stdio-common
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2017-08-22 07:47:34 -0700
committerH.J. Lu <hjl.tools@gmail.com>2017-08-22 07:50:57 -0700
commit20962acbea349b372311a727621c860006be3fab (patch)
tree4081bbaec7c838701452164cf6b0bfa2b8f70b43 /stdio-common
parenta16e8bc08edca84d507715c66d6cddbbc7ed3b62 (diff)
downloadglibc-20962acbea349b372311a727621c860006be3fab.tar.gz
glibc-20962acbea349b372311a727621c860006be3fab.tar.xz
glibc-20962acbea349b372311a727621c860006be3fab.zip
Hide internal printf functions [BZ #18822/21986]
Hide internal printf functions to allow direct access within libc.so and
libc.a without using GOT nor PLT.

Since __guess_grouping has been changed to take 2 arguments by

commit a1d84548c8aa7023cd039c85f81b831eef6d4a4c
Author: Ulrich Drepper <drepper@redhat.com>
Date:   Fri Feb 11 18:50:36 2000 +0000

the third argument passed to __guess_grouping is removed.

	[BZ #18822]
	[BZ #21986]
	* include/printf.h (__printf_fphex): Add attribute_hidden.
	(__guess_grouping): New prototype.
	* stdio-common/printf_fp.c (__guess_grouping): Removed.
	* stdio-common/reg-printf.c (__register_printf_specifier): Add
	libc_hidden_proto and libc_hidden_def.
	* stdlib/strfmon_l.c (__guess_grouping): Removed.
	(__vstrfmon_l): Remove the third argument passed to
	__guess_grouping.
Diffstat (limited to 'stdio-common')
-rw-r--r--stdio-common/printf_fp.c2
-rw-r--r--stdio-common/reg-printf.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/stdio-common/printf_fp.c b/stdio-common/printf_fp.c
index 3ed4037ba5..2633a02cc5 100644
--- a/stdio-common/printf_fp.c
+++ b/stdio-common/printf_fp.c
@@ -139,8 +139,6 @@ extern mp_size_t __mpn_extract_double (mp_ptr res_ptr, mp_size_t size,
 extern mp_size_t __mpn_extract_long_double (mp_ptr res_ptr, mp_size_t size,
 					    int *expt, int *is_neg,
 					    long double value);
-extern unsigned int __guess_grouping (unsigned int intdig_max,
-				      const char *grouping);
 
 
 static wchar_t *group_number (wchar_t *buf, wchar_t *bufend,
diff --git a/stdio-common/reg-printf.c b/stdio-common/reg-printf.c
index cbb9307795..fed5a16a7b 100644
--- a/stdio-common/reg-printf.c
+++ b/stdio-common/reg-printf.c
@@ -32,6 +32,7 @@ __libc_lock_define_initialized (static, lock)
 
 int __register_printf_specifier (int, printf_function,
 				 printf_arginfo_size_function);
+libc_hidden_proto (__register_printf_specifier)
 int __register_printf_function (int, printf_function,
 				printf_arginfo_function);
 
@@ -72,6 +73,7 @@ __register_printf_specifier (int spec, printf_function converter,
 
   return result;
 }
+libc_hidden_def (__register_printf_specifier)
 weak_alias (__register_printf_specifier, register_printf_specifier)