Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit8758985

Browse files
committed
Prevent drop database failure from showing.
1 parent37e7c7d commit8758985

File tree

2 files changed

+10
-6
lines changed

2 files changed

+10
-6
lines changed

‎src/include/c.h

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
99
* Portions Copyright (c) 1994, Regents of the University of California
1010
*
11-
* $Id: c.h,v 1.66 2000/03/20 04:02:46 momjian Exp $
11+
* $Id: c.h,v 1.67 2000/04/12 05:24:50 momjian Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -531,9 +531,11 @@ typedef struct Exception
531531
*
532532
*/
533533
#defineTrap(condition,exception) \
534-
{ if ((assert_enabled) && (condition)) \
534+
do { \
535+
if ((assert_enabled) && (condition)) \
535536
ExceptionalCondition(CppAsString(condition), &(exception), \
536-
(char*)NULL, __FILE__, __LINE__); }
537+
(char*)NULL, __FILE__, __LINE__); \
538+
} while (0)
537539

538540
/*
539541
*TrapMacro is the same as Trap but it's intended for use in macros:
@@ -577,9 +579,11 @@ extern intassert_enabled;
577579
*
578580
*/
579581
#defineLogTrap(condition,exception,printArgs) \
580-
{ if ((assert_enabled) && (condition)) \
582+
do { \
583+
if ((assert_enabled) && (condition)) \
581584
ExceptionalCondition(CppAsString(condition), &(exception), \
582-
vararg_format printArgs, __FILE__, __LINE__); }
585+
vararg_format printArgs, __FILE__, __LINE__); \
586+
} while (0)
583587

584588
/*
585589
*LogTrapMacro is the same as LogTrap but it's intended for use in macros:

‎src/test/regress/checkresults

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
["$#"-eq 0 ]&&set regress.out
66

7-
forfilein`cat"$@"| grep'failed$'| cut -d"" -f 1`
7+
forfilein`cat"$@"| grep'failed$'|grep -v'^dropdb:'|cut -d"" -f 1`
88
do
99
echo"======$file ======"
1010
diff -w expected/$file.out results

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp