[uClibc-cvs] uClibc/extra/Configs Config.in,1.21,1.22
Erik Andersen
andersen at uclibc.org
Fri Aug 8 10:30:13 UTC 2003
Update of /var/cvs/uClibc/extra/Configs
In directory winder:/tmp/cvs-serv19464/extra/Configs
Modified Files:
Config.in
Log Message:
Add in a MALLOC_GLIBC_COMPAT option to let people decide if they
want glibc style malloc(0) behavior
Index: Config.in
===================================================================
RCS file: /var/cvs/uClibc/extra/Configs/Config.in,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -d -r1.21 -r1.22
--- Config.in 5 Aug 2003 05:54:28 -0000 1.21
+++ Config.in 8 Aug 2003 10:30:10 -0000 1.22
@@ -195,11 +195,28 @@
endchoice
+config MALLOC_GLIBC_COMPAT
+ bool "Malloc returns live pointer for malloc(0)"
+ default n
+ help
+ The behavior of malloc(0) is listed as implementation-defined by
+ SuSv3. Glibc returns a valid pointer to something, while uClibc
+ normally return a NULL. I personally feel glibc's behavior is
+ not particularly safe, and allows buggy applications to hide very
+ serious problems.
+
+ When this option is enabled, uClibc will act just like glibc, and
+ return a live pointer when someone calls malloc(0). This pointer
+ provides a malloc'ed area with a size of 1 byte. This feature is
+ mostly useful when dealing with applications using autoconf's broken
+ AC_FUNC_MALLOC macro (which redefines malloc as rpl_malloc if it
+ does not detect glibc style returning-a-valid-pointer-for-malloc(0)
+ behavior). Most people can safely answer N.
+
config UCLIBC_DYNAMIC_ATEXIT
bool "Dynamic atexit() Support"
default y
help
-
When this option is enabled, uClibc will support an infinite number,
of atexit() and on_exit() functions, limited only by your available
memory. This can be important when uClibc is used with C++, since
More information about the uClibc-cvs
mailing list