about summary refs log tree commit diff
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2017-10-01 17:59:51 -0700
committerH.J. Lu <hjl.tools@gmail.com>2017-10-01 18:00:07 -0700
commit0e7d5b6e241b3e367b806f65f6df1e7469af68fa (patch)
tree1ccbec953532719e3cdfa049a1bb5493f5d8a9ea
parentbde06c87b7de97b5cd4721414b11af6e0d09187e (diff)
downloadglibc-0e7d5b6e241b3e367b806f65f6df1e7469af68fa.tar.gz
glibc-0e7d5b6e241b3e367b806f65f6df1e7469af68fa.tar.xz
glibc-0e7d5b6e241b3e367b806f65f6df1e7469af68fa.zip
Hide internal __new_getrlimit function [BZ #18822]
Hide internal __new_getrlimit function to allow direct access within
libc.so and libc.a without using GOT nor PLT.

	[BZ #18822]
	* sysdeps/unix/sysv/linux/getrlimit64.c (__new_getrlimit): Add
	attribute_hidden.
-rw-r--r--ChangeLog6
-rw-r--r--sysdeps/unix/sysv/linux/getrlimit64.c3
2 files changed, 8 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 85e4e02941..0e4520c8ca 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,12 @@
 2017-10-01  H.J. Lu  <hongjiu.lu@intel.com>
 
 	[BZ #18822]
+	* sysdeps/unix/sysv/linux/getrlimit64.c (__new_getrlimit): Add
+	attribute_hidden.
+
+2017-10-01  H.J. Lu  <hongjiu.lu@intel.com>
+
+	[BZ #18822]
 	* stdlib/exit.h (__new_exitfn): Add attribute_hidden.
 
 2017-10-01  H.J. Lu  <hongjiu.lu@intel.com>
diff --git a/sysdeps/unix/sysv/linux/getrlimit64.c b/sysdeps/unix/sysv/linux/getrlimit64.c
index 56af3c0646..37827e5f42 100644
--- a/sysdeps/unix/sysv/linux/getrlimit64.c
+++ b/sysdeps/unix/sysv/linux/getrlimit64.c
@@ -53,7 +53,8 @@ weak_alias (__getrlimit64, getrlimit)
 
 #if SHLIB_COMPAT (libc, GLIBC_2_1, GLIBC_2_2)
 /* Back compatible 2GiB limited rlimit.  */
-extern int __new_getrlimit (enum __rlimit_resource, struct rlimit *);
+extern int __new_getrlimit (enum __rlimit_resource, struct rlimit *)
+  attribute_hidden;
 
 int
 attribute_compat_text_section