[git commit ldso-future] ssp-local.c: make sure that -fstack-protector is not enabled when compiling file

Peter S. Mazinger ps.m at gmx.net
Wed Apr 13 17:38:40 UTC 2011


commit: http://git.uclibc.org/uClibc/commit/?id=f09787cc860748b24aa76b8b743b3de42e60d522
branch: http://git.uclibc.org/uClibc/commit/?id=refs/heads/ldso-future

Signed-off-by: Peter S. Mazinger <ps.m at gmx.net>
---
 libc/sysdeps/linux/common/ssp-local.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/libc/sysdeps/linux/common/ssp-local.c b/libc/sysdeps/linux/common/ssp-local.c
index 6b1809a..bea11a8 100644
--- a/libc/sysdeps/linux/common/ssp-local.c
+++ b/libc/sysdeps/linux/common/ssp-local.c
@@ -21,6 +21,10 @@
  * copied stack_chk_fail_local.c from glibc and adapted for uClibc
  */
 
+#if defined __SSP__ || defined __SSP_ALL__
+# error "file must not be compiled with stack protection enabled on it. Use -fno-stack-protector"
+#endif
+
 #include <features.h>
 
 /* On some architectures, this helps needless PIC pointer setup
@@ -29,5 +33,5 @@
 void __stack_chk_fail_local (void) attribute_noreturn attribute_hidden;
 void __stack_chk_fail_local (void)
 {
-  __stack_chk_fail ();
+	__stack_chk_fail ();
 }
-- 
1.7.3.4



More information about the uClibc-cvs mailing list