提交 c5354dff 编写于 作者: B Bruce Momjian

This patch removes a lot of unused code related to assertions and

error handling, and simplifies the code that remains. Apparently,
the code that left Berkeley had a whole "error handling subsystem",
which exceptions and whatnot. Since we don't use that anymore,
there's no reason to keep it around.

The regression tests pass with the patch applied. Unless anyone
sees a problem, please apply.

Neil Conway
上级 8be9bd83
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
* Portions Copyright (c) 1994, Regents of the University of California * Portions Copyright (c) 1994, Regents of the University of California
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/bootstrap/bootstrap.c,v 1.136 2002/08/04 06:26:38 thomas Exp $ * $Header: /cvsroot/pgsql/src/backend/bootstrap/bootstrap.c,v 1.137 2002/08/10 20:29:17 momjian Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -37,7 +37,6 @@ ...@@ -37,7 +37,6 @@
#include "storage/proc.h" #include "storage/proc.h"
#include "tcop/tcopprot.h" #include "tcop/tcopprot.h"
#include "utils/builtins.h" #include "utils/builtins.h"
#include "utils/exc.h"
#include "utils/fmgroids.h" #include "utils/fmgroids.h"
#include "utils/guc.h" #include "utils/guc.h"
#include "utils/lsyscache.h" #include "utils/lsyscache.h"
...@@ -238,7 +237,6 @@ BootstrapMain(int argc, char *argv[]) ...@@ -238,7 +237,6 @@ BootstrapMain(int argc, char *argv[])
*/ */
if (!IsUnderPostmaster) if (!IsUnderPostmaster)
{ {
EnableExceptionHandling(true);
MemoryContextInit(); MemoryContextInit();
} }
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/port/ipc_test.c,v 1.3 2002/06/20 20:29:33 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/port/ipc_test.c,v 1.4 2002/08/10 20:29:18 momjian Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -34,7 +34,6 @@ ...@@ -34,7 +34,6 @@
#include "storage/ipc.h" #include "storage/ipc.h"
#include "storage/pg_sema.h" #include "storage/pg_sema.h"
#include "storage/pg_shmem.h" #include "storage/pg_shmem.h"
#include "utils/exc.h"
/********* stuff needed to satisfy references in shmem/sema code *********/ /********* stuff needed to satisfy references in shmem/sema code *********/
...@@ -56,8 +55,6 @@ int NBuffers = DEF_NBUFFERS; ...@@ -56,8 +55,6 @@ int NBuffers = DEF_NBUFFERS;
bool assert_enabled = true; bool assert_enabled = true;
#endif #endif
Exception FailedAssertion = {"Failed Assertion"};
#define MAX_ON_EXITS 20 #define MAX_ON_EXITS 20
...@@ -120,14 +117,12 @@ ProcessInterrupts(void) ...@@ -120,14 +117,12 @@ ProcessInterrupts(void)
int int
ExceptionalCondition(char *conditionName, ExceptionalCondition(char *conditionName,
Exception *exceptionP, char *errorType,
char *detail,
char *fileName, char *fileName,
int lineNumber) int lineNumber)
{ {
fprintf(stderr, "TRAP: %s(\"%s:%s\", File: \"%s\", Line: %d)\n", fprintf(stderr, "TRAP: %s(\"%s\", File: \"%s\", Line: %d)\n",
exceptionP->message, conditionName, errorType, conditionName,
(detail == NULL ? "" : detail),
fileName, lineNumber); fileName, lineNumber);
abort(); abort();
return 0; return 0;
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.282 2002/08/04 06:26:38 thomas Exp $ * $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.283 2002/08/10 20:29:18 momjian Exp $
* *
* NOTES * NOTES
* *
...@@ -102,7 +102,6 @@ ...@@ -102,7 +102,6 @@
#include "storage/proc.h" #include "storage/proc.h"
#include "access/xlog.h" #include "access/xlog.h"
#include "tcop/tcopprot.h" #include "tcop/tcopprot.h"
#include "utils/exc.h"
#include "utils/guc.h" #include "utils/guc.h"
#include "utils/memutils.h" #include "utils/memutils.h"
#include "utils/ps_status.h" #include "utils/ps_status.h"
...@@ -380,9 +379,8 @@ PostmasterMain(int argc, char *argv[]) ...@@ -380,9 +379,8 @@ PostmasterMain(int argc, char *argv[])
MyProcPid = getpid(); MyProcPid = getpid();
/* /*
* Fire up essential subsystems: error and memory management * Fire up essential subsystems: memory management
*/ */
EnableExceptionHandling(true);
MemoryContextInit(); MemoryContextInit();
/* /*
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.280 2002/08/06 05:24:04 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.281 2002/08/10 20:29:18 momjian Exp $
* *
* NOTES * NOTES
* this is the "main" module of the postgres backend and * this is the "main" module of the postgres backend and
...@@ -54,7 +54,6 @@ ...@@ -54,7 +54,6 @@
#include "tcop/pquery.h" #include "tcop/pquery.h"
#include "tcop/tcopprot.h" #include "tcop/tcopprot.h"
#include "tcop/utility.h" #include "tcop/utility.h"
#include "utils/exc.h"
#include "utils/guc.h" #include "utils/guc.h"
#include "utils/memutils.h" #include "utils/memutils.h"
#include "utils/ps_status.h" #include "utils/ps_status.h"
...@@ -1148,7 +1147,6 @@ PostgresMain(int argc, char *argv[], const char *username) ...@@ -1148,7 +1147,6 @@ PostgresMain(int argc, char *argv[], const char *username)
*/ */
if (!IsUnderPostmaster) if (!IsUnderPostmaster)
{ {
EnableExceptionHandling(true);
MemoryContextInit(); MemoryContextInit();
} }
...@@ -1676,7 +1674,7 @@ PostgresMain(int argc, char *argv[], const char *username) ...@@ -1676,7 +1674,7 @@ PostgresMain(int argc, char *argv[], const char *username)
if (!IsUnderPostmaster) if (!IsUnderPostmaster)
{ {
puts("\nPOSTGRES backend interactive interface "); puts("\nPOSTGRES backend interactive interface ");
puts("$Revision: 1.280 $ $Date: 2002/08/06 05:24:04 $\n"); puts("$Revision: 1.281 $ $Date: 2002/08/10 20:29:18 $\n");
} }
/* /*
...@@ -2074,35 +2072,6 @@ ShowUsage(const char *title) ...@@ -2074,35 +2072,6 @@ ShowUsage(const char *title)
pfree(str.data); pfree(str.data);
} }
#ifdef NOT_USED
static int
assertEnable(int val)
{
assert_enabled = val;
return val;
}
#ifdef ASSERT_CHECKING_TEST
int
assertTest(int val)
{
Assert(val == 0);
if (assert_enabled)
{
/* val != 0 should be trapped by previous Assert */
elog(DEBUG3, "Assert test successful (val = %d)", val);
}
else
elog(DEBUG3, "Assert checking is disabled (val = %d)", val);
return val;
}
#endif
#endif
/* ---------------------------------------------------------------- /* ----------------------------------------------------------------
* CreateCommandTag * CreateCommandTag
* *
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
# Makefile for utils/error # Makefile for utils/error
# #
# IDENTIFICATION # IDENTIFICATION
# $Header: /cvsroot/pgsql/src/backend/utils/error/Makefile,v 1.9 2000/08/31 16:10:48 petere Exp $ # $Header: /cvsroot/pgsql/src/backend/utils/error/Makefile,v 1.10 2002/08/10 20:29:18 momjian Exp $
# #
#------------------------------------------------------------------------- #-------------------------------------------------------------------------
...@@ -12,7 +12,7 @@ subdir = src/backend/utils/error ...@@ -12,7 +12,7 @@ subdir = src/backend/utils/error
top_builddir = ../../../.. top_builddir = ../../../..
include $(top_builddir)/src/Makefile.global include $(top_builddir)/src/Makefile.global
OBJS = assert.o elog.o exc.o excabort.o excid.o format.o OBJS = assert.o elog.o
all: SUBSYS.o all: SUBSYS.o
......
...@@ -8,65 +8,44 @@ ...@@ -8,65 +8,44 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/assert.c,v 1.21 2002/06/20 20:29:39 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/error/assert.c,v 1.22 2002/08/10 20:29:18 momjian Exp $
* *
* NOTE * NOTE
* This should eventually work with elog(), dlog(), etc. * This should eventually work with elog()
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h" #include "postgres.h"
#include <stdio.h>
#include <unistd.h> #include <unistd.h>
#include "utils/exc.h" /*
* ExceptionalCondition - Handles the failure of an Assert()
*/
int int
ExceptionalCondition(char *conditionName, ExceptionalCondition(char *conditionName,
Exception *exceptionP, char *errorType,
char *detail,
char *fileName, char *fileName,
int lineNumber) int lineNumber)
{ {
ExcFileName = fileName;
ExcLineNumber = lineNumber;
if (!PointerIsValid(conditionName) if (!PointerIsValid(conditionName)
|| !PointerIsValid(fileName) || !PointerIsValid(fileName)
|| !PointerIsValid(exceptionP)) || !PointerIsValid(errorType))
{ {
fprintf(stderr, "TRAP: ExceptionalCondition: bad arguments\n"); fprintf(stderr, "TRAP: ExceptionalCondition: bad arguments\n");
ExcAbort(exceptionP,
(ExcDetail) detail,
(ExcData) NULL,
(ExcMessage) NULL);
} }
else else
{ {
fprintf(stderr, "TRAP: %s(\"%s:%s\", File: \"%s\", Line: %d)\n", fprintf(stderr, "TRAP: %s(\"%s\", File: \"%s\", Line: %d)\n",
exceptionP->message, conditionName, errorType, conditionName,
(detail == NULL ? "" : detail),
fileName, lineNumber); fileName, lineNumber);
} }
#ifdef ABORT_ON_ASSERT
abort();
#endif
#ifdef SLEEP_ON_ASSERT #ifdef SLEEP_ON_ASSERT
sleep(1000000); sleep(1000000);
#endif #endif
/* abort();
* XXX Depending on the Exception and tracing conditions, you will XXX
* want to stop here immediately and maybe dump core. XXX This may be
* especially true for Assert(), etc.
*/
/* TraceDump(); dump the trace stack */
/* XXX FIXME: detail is lost */
ExcRaise(exceptionP, (ExcDetail) 0, (ExcData) NULL, conditionName);
return 0; return 0;
} }
/*-------------------------------------------------------------------------
*
* exc.c
* POSTGRES exception handling code.
*
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/exc.c,v 1.39 2002/06/20 20:29:39 momjian Exp $
*
* NOTE
* XXX this code needs improvement--check for state violations and
* XXX reset after handling an exception.
* XXX Probably should be merged with elog.c.
*
*-------------------------------------------------------------------------
*/
#include "postgres.h"
#include <errno.h>
#include "storage/ipc.h"
#include "utils/exc.h"
extern int errno;
static void ExcUnCaught(Exception *excP, ExcDetail detail, ExcData data,
ExcMessage message);
static void ExcPrint(Exception *excP, ExcDetail detail, ExcData data,
ExcMessage message);
/*
* Global Variables
*/
static bool ExceptionHandlingEnabled = false;
char *ExcFileName = NULL;
Index ExcLineNumber = 0;
ExcFrame *ExcCurFrameP = NULL;
static ExcProc *ExcUnCaughtP = NULL;
/*
* Exported Functions
*/
/*
* EnableExceptionHandling
* Enables/disables the exception handling system.
*
* Note:
* This must be called before any exceptions occur. I.e., call this first!
* This routine will not return if an error is detected.
* This does not follow the usual Enable... protocol.
* This should be merged more closely with the error logging and tracing
* packages.
*
* Exceptions:
* none
*/
/*
* Excection handling should be supported by the language, thus there should
* be no need to explicitly enable exception processing.
*
* This function should probably not be called, ever. Currently it does
* almost nothing. If there is a need for this intialization and checking.
* then this function should be converted to the new-style Enable code and
* called by all the other module Enable functions.
*/
void
EnableExceptionHandling(bool on)
{
if (on == ExceptionHandlingEnabled)
{
/* XXX add logging of failed state */
proc_exit(255);
/* ExitPostgres(FatalExitStatus); */
}
if (on)
{ /* initialize */
;
}
else
{ /* cleanup */
ExcFileName = NULL;
ExcLineNumber = 0;
ExcCurFrameP = NULL;
ExcUnCaughtP = NULL;
}
ExceptionHandlingEnabled = on;
}
static void
ExcPrint(Exception *excP,
ExcDetail detail,
ExcData data,
ExcMessage message)
{
/* this buffer is only used if errno has a bogus value: */
char errorstr_buf[32];
const char *errorstr;
#ifdef lint
data = data;
#endif
/* Save error str before calling any function that might change errno */
errorstr = strerror(errno);
/*
* Some strerror()s return an empty string for out-of-range errno.
* This is ANSI C spec compliant, but not exactly useful.
*/
if (errorstr == NULL || *errorstr == '\0')
{
sprintf(errorstr_buf, "error %d", errno);
errorstr = errorstr_buf;
}
fflush(stdout); /* In case stderr is buffered */
if (message != NULL)
fprintf(stderr, "%s", message);
else if (excP->message != NULL)
fprintf(stderr, "%s", excP->message);
else
fprintf(stderr, "UNNAMED EXCEPTION %p", excP);
fprintf(stderr, " (%ld) [%s]\n", detail, errorstr);
fflush(stderr);
}
#ifdef NOT_USED
ExcProc *
ExcGetUnCaught(void)
{
return ExcUnCaughtP;
}
#endif
#ifdef NOT_USED
ExcProc *
ExcSetUnCaught(ExcProc *newP)
{
ExcProc *oldP = ExcUnCaughtP;
ExcUnCaughtP = newP;
return oldP;
}
#endif
static void
ExcUnCaught(Exception *excP,
ExcDetail detail,
ExcData data,
ExcMessage message)
{
ExcPrint(excP, detail, data, message);
ExcAbort(excP, detail, data, message);
}
void
ExcRaise(Exception *excP,
ExcDetail detail,
ExcData data,
ExcMessage message)
{
ExcFrame *efp;
efp = ExcCurFrameP;
if (efp == NULL)
{
if (ExcUnCaughtP != NULL)
(*ExcUnCaughtP) (excP, detail, data, message);
ExcUnCaught(excP, detail, data, message);
}
else
{
efp->id = excP;
efp->detail = detail;
efp->data = data;
efp->message = message;
ExcCurFrameP = efp->link;
siglongjmp(efp->context, 1);
}
}
/*-------------------------------------------------------------------------
*
* excabort.c
* Default exception abort code.
*
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/excabort.c,v 1.10 2002/06/20 20:29:39 momjian Exp $
*
*-------------------------------------------------------------------------
*/
#include "postgres.h"
#include "utils/exc.h"
void
ExcAbort(const Exception *excP,
ExcDetail detail,
ExcData data,
ExcMessage message)
{
/* dump core */
abort();
}
/*-------------------------------------------------------------------------
*
* excid.c
* POSTGRES known exception identifier code.
*
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/excid.c,v 1.11 2002/06/20 20:29:39 momjian Exp $
*
*-------------------------------------------------------------------------
*/
#include "postgres.h"
/*****************************************************************************
* Generic Recoverable Exceptions *
*****************************************************************************/
/*
* FailedAssertion
* Indicates an Assert(...) failed.
*/
Exception FailedAssertion = {"Failed Assertion"};
/*
* BadState
* Indicates a function call request is inconsistent with module state.
*/
Exception BadState = {"Bad State for Function Call"};
/*
* BadArg
* Indicates a function call argument or arguments is out-of-bounds.
*/
Exception BadArg = {"Bad Argument to Function Call"};
/*****************************************************************************
* Specific Recoverable Exceptions *
*****************************************************************************/
/*
* Unimplemented
* Indicates a function call request requires unimplemented code.
*/
Exception Unimplemented = {"Unimplemented Functionality"};
Exception CatalogFailure = {"Catalog failure"}; /* XXX inconsistent */
Exception InternalError = {"Internal Error"}; /* XXX inconsistent */
Exception SemanticError = {"Semantic Error"}; /* XXX inconsistent */
Exception SystemError = {"System Error"}; /* XXX inconsistent */
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/mmgr/mcxt.c,v 1.30 2002/06/20 20:29:40 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/mmgr/mcxt.c,v 1.31 2002/08/10 20:29:18 momjian Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -22,7 +22,6 @@ ...@@ -22,7 +22,6 @@
#include "postgres.h" #include "postgres.h"
#include "nodes/memnodes.h" #include "nodes/memnodes.h"
#include "utils/excid.h"
#include "utils/memutils.h" #include "utils/memutils.h"
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group * Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
* Portions Copyright (c) 1995, Regents of the University of California * Portions Copyright (c) 1995, Regents of the University of California
* *
* $Id: postgres.h,v 1.58 2002/06/20 20:29:42 momjian Exp $ * $Id: postgres.h,v 1.59 2002/08/10 20:29:18 momjian Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -470,17 +470,6 @@ extern Datum Float8GetDatum(float8 X); ...@@ -470,17 +470,6 @@ extern Datum Float8GetDatum(float8 X);
* ---------------------------------------------------------------- * ----------------------------------------------------------------
*/ */
typedef char *ExcMessage;
typedef struct Exception
{
ExcMessage message;
} Exception;
extern DLLIMPORT Exception FailedAssertion;
extern DLLIMPORT Exception BadArg;
extern DLLIMPORT Exception BadState;
extern DLLIMPORT bool assert_enabled; extern DLLIMPORT bool assert_enabled;
/* /*
...@@ -495,25 +484,24 @@ extern DLLIMPORT bool assert_enabled; ...@@ -495,25 +484,24 @@ extern DLLIMPORT bool assert_enabled;
* Generates an exception if the given condition is true. * Generates an exception if the given condition is true.
* *
*/ */
#define Trap(condition, exception) \ #define Trap(condition, errorType) \
do { \ do { \
if ((assert_enabled) && (condition)) \ if ((assert_enabled) && (condition)) \
ExceptionalCondition(CppAsString(condition), &(exception), \ ExceptionalCondition(CppAsString(condition), (errorType), \
(char*)NULL, __FILE__, __LINE__); \ __FILE__, __LINE__); \
} while (0) } while (0)
/* /*
* TrapMacro is the same as Trap but it's intended for use in macros: * TrapMacro is the same as Trap but it's intended for use in macros:
* *
* #define foo(x) (AssertM(x != 0) && bar(x)) * #define foo(x) (AssertMacro(x != 0) && bar(x))
* *
* Isn't CPP fun? * Isn't CPP fun?
*/ */
#define TrapMacro(condition, exception) \ #define TrapMacro(condition, errorType) \
((bool) ((! assert_enabled) || ! (condition) || \ ((bool) ((! assert_enabled) || ! (condition) || \
(ExceptionalCondition(CppAsString(condition), \ (ExceptionalCondition(CppAsString(condition), (errorType), \
&(exception), \ __FILE__, __LINE__))))
(char*) NULL, __FILE__, __LINE__))))
#ifndef USE_ASSERT_CHECKING #ifndef USE_ASSERT_CHECKING
#define Assert(condition) #define Assert(condition)
...@@ -523,73 +511,21 @@ extern DLLIMPORT bool assert_enabled; ...@@ -523,73 +511,21 @@ extern DLLIMPORT bool assert_enabled;
#define assert_enabled 0 #define assert_enabled 0
#else #else
#define Assert(condition) \ #define Assert(condition) \
Trap(!(condition), FailedAssertion) Trap(!(condition), "FailedAssertion")
#define AssertMacro(condition) \ #define AssertMacro(condition) \
((void) TrapMacro(!(condition), FailedAssertion)) ((void) TrapMacro(!(condition), "FailedAssertion"))
#define AssertArg(condition) \ #define AssertArg(condition) \
Trap(!(condition), BadArg) Trap(!(condition), "BadArgument")
#define AssertState(condition) \ #define AssertState(condition) \
Trap(!(condition), BadState) Trap(!(condition), "BadState")
#endif /* USE_ASSERT_CHECKING */ #endif /* USE_ASSERT_CHECKING */
/* extern int ExceptionalCondition(char *conditionName, char *errorType,
* LogTrap
* Generates an exception with a message if the given condition is true.
*
*/
#define LogTrap(condition, exception, printArgs) \
do { \
if ((assert_enabled) && (condition)) \
ExceptionalCondition(CppAsString(condition), &(exception), \
vararg_format printArgs, __FILE__, __LINE__); \
} while (0)
/*
* LogTrapMacro is the same as LogTrap but it's intended for use in macros:
*
* #define foo(x) (LogAssertMacro(x != 0, "yow!") && bar(x))
*/
#define LogTrapMacro(condition, exception, printArgs) \
((bool) ((! assert_enabled) || ! (condition) || \
(ExceptionalCondition(CppAsString(condition), \
&(exception), \
vararg_format printArgs, __FILE__, __LINE__))))
extern int ExceptionalCondition(char *conditionName,
Exception *exceptionP, char *details,
char *fileName, int lineNumber); char *fileName, int lineNumber);
extern char *
vararg_format(const char *fmt,...)
/* This lets gcc check the format string for consistency. */
__attribute__((format(printf, 1, 2)));
#ifndef USE_ASSERT_CHECKING
#define LogAssert(condition, printArgs)
#define LogAssertMacro(condition, printArgs) true
#define LogAssertArg(condition, printArgs)
#define LogAssertState(condition, printArgs)
#else
#define LogAssert(condition, printArgs) \
LogTrap(!(condition), FailedAssertion, printArgs)
#define LogAssertMacro(condition, printArgs) \
LogTrapMacro(!(condition), FailedAssertion, printArgs)
#define LogAssertArg(condition, printArgs) \
LogTrap(!(condition), BadArg, printArgs)
#define LogAssertState(condition, printArgs) \
LogTrap(!(condition), BadState, printArgs)
#ifdef ASSERT_CHECKING_TEST
extern int assertTest(int val);
#endif
#endif /* USE_ASSERT_CHECKING */
/* ---------------------------------------------------------------- /* ----------------------------------------------------------------
* Section 4: genbki macros used by catalog/pg_xxx.h files * Section 4: genbki macros used by catalog/pg_xxx.h files
* ---------------------------------------------------------------- * ----------------------------------------------------------------
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册