Commit a73c9dba authored by Fujii Masao's avatar Fujii Masao

Fix segmentation fault that an empty prepared statement could cause.

Back-patch to all supported branches.

Per bug #11335 from Haruka Takatsuka
parent d8d4965d
...@@ -2461,6 +2461,9 @@ GetCommandLogLevel(Node *parsetree) ...@@ -2461,6 +2461,9 @@ GetCommandLogLevel(Node *parsetree)
{ {
LogStmtLevel lev; LogStmtLevel lev;
if (parsetree == NULL)
return LOGSTMT_ALL;
switch (nodeTag(parsetree)) switch (nodeTag(parsetree))
{ {
/* raw plannable queries */ /* raw plannable queries */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment