mirror of
https://github.com/postgres/postgres.git
synced 2025-04-22 23:02:54 +03:00
Plug hole in dike: planner would coredump if query_planner
returned NULL, which it will do in some cases where an elog(ERROR) would probably 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 of returning NULL, but this is at least a safe change for now.
This commit is contained in:
parent
1918a1d191
commit
acf242da97
@ -7,7 +7,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.55 1999/06/06 17:38:10 tgl Exp $
|
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.56 1999/06/12 19:27:41 tgl Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -223,6 +223,10 @@ union_planner(Query *parse)
|
|||||||
pfree(vpm);
|
pfree(vpm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* query_planner returns NULL if it thinks plan is bogus */
|
||||||
|
if (! result_plan)
|
||||||
|
elog(ERROR, "union_planner: failed to create plan");
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If we have a GROUP BY clause, insert a group node (with the
|
* If we have a GROUP BY clause, insert a group node (with the
|
||||||
* appropriate sort node.)
|
* appropriate sort node.)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user