Skip to content

Commit

Permalink
COMMON: Add abort() to the list of forbidden symbols
Browse files Browse the repository at this point in the history
  • Loading branch information
Templier committed Jun 23, 2011
1 parent 7fa3a8b commit 53c4a19
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion common/forbidden.h
Expand Up @@ -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.
Expand Down Expand Up @@ -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
Expand Down

0 comments on commit 53c4a19

Please sign in to comment.