COMMON: Add abort() to the list of forbidden symbols

This commit is contained in:
Julien 2011-06-07 00:46:09 +08:00 committed by Julien
parent 7fa3a8bbff
commit 53c4a190fc

View File

@ -29,7 +29,7 @@
* infrastructure code do not make use of certain "forbidden" APIs, such
* as fopen(), setjmp(), etc.
* This is achieved by re-#defining various symbols to a "garbage"
* string which then trigers a compiler error.
* string which then triggers a compiler error.
*
* Backend files may #define FORBIDDEN_SYMBOL_ALLOW_ALL if they
* have to access functions like fopen, fread etc.
@ -203,6 +203,11 @@
#define exit(a) FORBIDDEN_SYMBOL_REPLACEMENT
#endif
#ifndef FORBIDDEN_SYMBOL_EXCEPTION_abort
#undef abort
#define abort() FORBIDDEN_SYMBOL_REPLACEMENT
#endif
#ifndef FORBIDDEN_SYMBOL_EXCEPTION_getenv
#undef getenv
#define getenv(a) FORBIDDEN_SYMBOL_REPLACEMENT