mirror of https://github.com/citusdata/citus.git
Avoid segfault in logging queries
parent
e88cb8335f
commit
064bd66a20
|
@ -442,7 +442,7 @@ ExecuteQueryIntoDestReceiver(Query *query, ParamListInfo params, DestReceiver *d
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* ExecuteIntoDestReceiver plans and executes a query and sends results to the given
|
* ExecutePlanIntoDestReceiver executes a query plan and sends results to the given
|
||||||
* DestReceiver.
|
* DestReceiver.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
|
|
|
@ -111,6 +111,7 @@ RebuildQueryStrings(Query *originalQuery, List *taskList)
|
||||||
}
|
}
|
||||||
|
|
||||||
ereport(DEBUG4, (errmsg("query before rebuilding: %s",
|
ereport(DEBUG4, (errmsg("query before rebuilding: %s",
|
||||||
|
task->queryString == NULL ? "(null)" :
|
||||||
ApplyLogRedaction(task->queryString))));
|
ApplyLogRedaction(task->queryString))));
|
||||||
|
|
||||||
UpdateTaskQueryString(query, relationId, valuesRTE, task);
|
UpdateTaskQueryString(query, relationId, valuesRTE, task);
|
||||||
|
|
|
@ -175,9 +175,8 @@ _PG_init(void)
|
||||||
* (thus as the innermost/last running hook) to be able to do our
|
* (thus as the innermost/last running hook) to be able to do our
|
||||||
* duties. For simplicity insist that all hooks are previously unused.
|
* duties. For simplicity insist that all hooks are previously unused.
|
||||||
*/
|
*/
|
||||||
if (planner_hook != NULL || ProcessUtility_hook != NULL || ExecutorStart_hook !=
|
if (planner_hook != NULL || ProcessUtility_hook != NULL ||
|
||||||
NULL ||
|
ExecutorStart_hook != NULL || ExecutorRun_hook != NULL)
|
||||||
ExecutorRun_hook != NULL)
|
|
||||||
{
|
{
|
||||||
ereport(ERROR, (errmsg("Citus has to be loaded first"),
|
ereport(ERROR, (errmsg("Citus has to be loaded first"),
|
||||||
errhint("Place citus at the beginning of "
|
errhint("Place citus at the beginning of "
|
||||||
|
|
Loading…
Reference in New Issue