uclibc: Make the oomsimulator compile with uclibc
In the infinite wisdom uclibc defines __GLIBC__ but is not a full drop-in replacement for the GLIBC. Check for !UCLIBC. Make sure there is a disableHooks in case the GLIBC code is not compiled Change-Id: I246d3ee7c1d3f48f7f6445daa01a4f001b9a3cb0 Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com>bb10
parent
ece8f9cd51
commit
c226021600
|
|
@ -59,7 +59,7 @@ static void my_terminate_handler()
|
|||
exit(1);
|
||||
}
|
||||
|
||||
#ifdef __GLIBC__
|
||||
#if defined(__GLIBC__) && !defined(__UCLIBC__)
|
||||
/* Use glibc's memory allocation hooks */
|
||||
|
||||
// From glibc 2.14, the malloc hook variables are declared volatile.
|
||||
|
|
@ -195,6 +195,12 @@ static struct QCrtDebugRegistrator
|
|||
|
||||
} crtDebugRegistrator;
|
||||
|
||||
#else
|
||||
|
||||
static void disableHooks()
|
||||
{
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
struct AllocFailer
|
||||
|
|
|
|||
Loading…
Reference in New Issue