[uClibc-cvs] uClibc/libc/misc/internals __uClibc_main.c,1.29,1.30

Erik Andersen andersen at uclibc.org
Fri Jan 2 23:34:14 UTC 2004


Update of /var/cvs/uClibc/libc/misc/internals
In directory nail:/tmp/cvs-serv1058/libc/misc/internals

Modified Files:
	__uClibc_main.c 
Log Message:
Peter S. Mazinger writes:

Hello Erik!

I have made some cosmetical changes to the files, removed the added 
SCRT=-fPIC option from building the crt0.S file (but it is a requirement 
to build them with -fPIC), and changed some comments. I have left the 
ldso.c patch with PIE_SUPPORT ifdefs, but consider applying it w/o them 
(see some earlier comment from PaX Team on this issue, as it is considered 
a bug). To have it work correctly, you'll also need removing 
COMPLETELY_PIC.
One thing is missing: PIE_SUPPORT should be usable only for i386 (for 
now).

Also added the support for propolice protection (that works for me and 
catches memcpy/strcpy attacks (but needs a special gcc version).

Thanks, Peter



Index: __uClibc_main.c
===================================================================
RCS file: /var/cvs/uClibc/libc/misc/internals/__uClibc_main.c,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -d -r1.29 -r1.30
--- __uClibc_main.c	27 Dec 2003 23:36:22 -0000	1.29
+++ __uClibc_main.c	2 Jan 2004 23:34:11 -0000	1.30
@@ -15,6 +15,9 @@
 #include <features.h>
 #include <unistd.h>
 #include <stdlib.h>
+#ifdef __UCLIBC_PROPOLICE__
+extern void __guard_setup(void);
+#endif
 
 
 /*
@@ -139,6 +142,10 @@
     }
 #endif
 
+#ifdef __UCLIBC_PROPOLICE__
+     __guard_setup ();
+#endif
+
     /* Note: It is possible that any initialization done above could
      * have resulted in errno being set nonzero, so set it to 0 before
      * we call main.




More information about the uClibc-cvs mailing list