This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] execstack failure.


Hi,
using __builtin_return_address without __builtin_extract_return_addr
doesn't work on s390-32. The RETURN_ADDRESS macro should be used
instead.

blue skies,
  Martin.

2004-04-20  Martin Schwidefsky  <schwidefsky@de.ibm.com>

	* sysdeps/unix/sysv/linux/dl-execstack.c (_dl_make_stack_executable): 
	Use RETURN_ADDRESS instead of __builtin_return_address.

diff -urN libc/sysdeps/unix/sysv/linux/dl-execstack.c libc-execstack/sysdeps/unix/sysv/linux/dl-execstack.c
--- libc/sysdeps/unix/sysv/linux/dl-execstack.c	2004-04-13 15:50:23.000000000 +0200
+++ libc-execstack/sysdeps/unix/sysv/linux/dl-execstack.c	2004-04-20 09:44:41.000000000 +0200
@@ -37,7 +37,7 @@
 		    & -(intptr_t) GLRO(dl_pagesize));
 
   /* Challenge the caller.  */
-  if (__builtin_expect (__check_caller (__builtin_return_address (0),
+  if (__builtin_expect (__check_caller (RETURN_ADDRESS(0),
 					allow_ldso|allow_libpthread) != 0, 0)
       || __builtin_expect (*stack_endp != __libc_stack_end, 0))
     return EPERM;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]