summaryrefslogtreecommitdiff
path: root/src/include/postgres.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/postgres.h')
-rw-r--r--src/include/postgres.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/include/postgres.h b/src/include/postgres.h
index 190df0ed9b..10b3d16760 100644
--- a/src/include/postgres.h
+++ b/src/include/postgres.h
@@ -7,7 +7,7 @@
* Client-side code should include postgres_fe.h instead.
*
*
- * Portions Copyright (c) 1996-2011, PostgreSQL Global Development Group
+ * Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group
* Portions Copyright (c) 1995, Regents of the University of California
* Portions Copyright (c) 2010-2012 Postgres-XC Development Group
*
@@ -656,14 +656,14 @@ extern PGDLLIMPORT bool assert_enabled;
/*
* TrapMacro is the same as Trap but it's intended for use in macros:
*
- * #define foo(x) (AssertMacro(x != 0) && bar(x))
+ * #define foo(x) (AssertMacro(x != 0), bar(x))
*
* Isn't CPP fun?
*/
#define TrapMacro(condition, errorType) \
((bool) ((! assert_enabled) || ! (condition) || \
(ExceptionalCondition(CppAsString(condition), (errorType), \
- __FILE__, __LINE__))))
+ __FILE__, __LINE__), 0)))
#ifndef USE_ASSERT_CHECKING
#define Assert(condition)
@@ -684,9 +684,9 @@ extern PGDLLIMPORT bool assert_enabled;
Trap(!(condition), "BadState")
#endif /* USE_ASSERT_CHECKING */
-extern int ExceptionalCondition(const char *conditionName,
+extern void ExceptionalCondition(const char *conditionName,
const char *errorType,
- const char *fileName, int lineNumber);
+ const char *fileName, int lineNumber) __attribute__((noreturn));
//#define PGXC_COORD // for PGXC coordinator compiling
//#define PGXC_DATANODE // for PGXC data node compiling