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

Commitacf242d

Browse files
committed
Plug hole in dike: planner would coredump if query_planner
returned NULL, which it will do in some cases where an elog(ERROR) wouldprobably be more appropriate. For the moment, generate a not-very-informative error message rather than proceeding to certain coredump.Probably ought to think about making query_planner elog instead ofreturning NULL, but this is at least a safe change for now.
1 parent1918a1d commitacf242d

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

‎src/backend/optimizer/plan/planner.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.55 1999/06/06 17:38:10 tgl Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.56 1999/06/12 19:27:41 tgl Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -223,6 +223,10 @@ union_planner(Query *parse)
223223
pfree(vpm);
224224
}
225225

226+
/* query_planner returns NULL if it thinks plan is bogus */
227+
if (!result_plan)
228+
elog(ERROR,"union_planner: failed to create plan");
229+
226230
/*
227231
* If we have a GROUP BY clause, insert a group node (with the
228232
* appropriate sort node.)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp