diff options
author | Michael Stone <michael@laptop.org> | 2009-04-12 18:36:23 (GMT) |
---|---|---|
committer | Michael Stone <michael@laptop.org> | 2009-04-12 18:36:23 (GMT) |
commit | 25499da9e71cc096765ffebbd60c4e798ae5f8ba (patch) | |
tree | 602f5ea97205ba220089806af3f0b9feb3a96440 /rainbow | |
parent | 07dde9ee384b08226d4d0e24929c4923b94d4a8e (diff) |
Disable nss debugging for release.
Diffstat (limited to 'rainbow')
-rw-r--r-- | rainbow/nss/cgen.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/rainbow/nss/cgen.h b/rainbow/nss/cgen.h index 6d9f48e..215dda0 100644 --- a/rainbow/nss/cgen.h +++ b/rainbow/nss/cgen.h @@ -1,9 +1,8 @@ #define STATIC_ASSERT(expr) extern char __static_assertion_failed [(expr) ? 1 : -1] #define SAVE_ERR(EXPR) {int __errno_save = errno; EXPR; errno = __errno_save;} #define __XSTRING(X) __STRING(X) -/* #define PERROR(msg) {int __errno_cache = errno; dprintf(2, "%s|%d| %s: %s\nError %d: %s\n", __FILE__, __LINE__, __func__, msg, __errno_cache, strerror(__errno_cache));} */ -#define PERROR(msg) {int __errno_cache = errno; if (getenv(DEBUG) != NULL) {dprintf(2, "%s|%d| %s: %s\n", __FILE__, __LINE__, __func__, msg); if (__errno_cache) {dprintf(2, "Error %d: %s\n", __errno_cache, strerror(__errno_cache));}};} -/* #define PERROR(msg) */ +/* #define PERROR(msg) {int __errno_cache = errno; if (getenv(DEBUG) != NULL) {dprintf(2, "%s|%d| %s: %s\n", __FILE__, __LINE__, __func__, msg); if (__errno_cache) {dprintf(2, "Error %d: %s\n", __errno_cache, strerror(__errno_cache));}};} */ +#define PERROR(msg) #define CHK(EXPR, MSG, ERR_LABEL) {if(EXPR) { PERROR(MSG); goto ERR_LABEL;}} #define LET(LETEXPR, CONDEXPR, MSG, ERR_LABEL) LETEXPR; if (CONDEXPR) { PERROR(MSG); goto ERR_LABEL;} #define TST(EXPR, ERRNO, MSG, ERR_LABEL) {if (EXPR) {errno = ERRNO; PERROR(MSG); goto ERR_LABEL;}} |