Merge pull request #591 from citusdata/fix_compile_time_warning_in_multi_logical_optimizer

Eliminate compile time warnings in multi_logical_optimizer.c
pull/586/head
Ahmet Eren Basak 2016-06-10 12:33:18 +03:00 committed by GitHub
commit bbf13be508
2 changed files with 10 additions and 6 deletions

View File

@ -2871,7 +2871,8 @@ TrackerHashCleanupJob(HTAB *taskTrackerHash, Task *jobCleanupTask)
{ {
ereport(WARNING, (errmsg("could not receive response for cleanup " ereport(WARNING, (errmsg("could not receive response for cleanup "
"query status for job " UINT64_FORMAT " " "query status for job " UINT64_FORMAT " "
"on node \"%s:%u\" with status %d", jobId, "on node \"%s:%u\" with status %d",
jobId,
nodeName, nodePort, (int) queryStatus), nodeName, nodePort, (int) queryStatus),
errhint("Manually clean job resources on node " errhint("Manually clean job resources on node "
"\"%s:%u\" by running \"%s\" ", nodeName, "\"%s:%u\" by running \"%s\" ", nodeName,
@ -2887,7 +2888,8 @@ TrackerHashCleanupJob(HTAB *taskTrackerHash, Task *jobCleanupTask)
{ {
ereport(WARNING, (errmsg("could not receive response for cleanup query " ereport(WARNING, (errmsg("could not receive response for cleanup query "
"result for job " UINT64_FORMAT " on node " "result for job " UINT64_FORMAT " on node "
"\"%s:%u\" with status %d", jobId, nodeName, "\"%s:%u\" with status %d",
jobId, nodeName,
nodePort, (int) resultStatus), nodePort, (int) resultStatus),
errhint("Manually clean job resources on node " errhint("Manually clean job resources on node "
"\"%s:%u\" by running \"%s\" ", nodeName, "\"%s:%u\" by running \"%s\" ", nodeName,

View File

@ -1705,9 +1705,10 @@ WorkerExtendedOpNode(MultiExtendedOp *originalOpNode)
AttrNumber targetProjectionNumber = 1; AttrNumber targetProjectionNumber = 1;
WorkerAggregateWalkerContext *walkerContext = WorkerAggregateWalkerContext *walkerContext =
palloc0(sizeof(WorkerAggregateWalkerContext)); palloc0(sizeof(WorkerAggregateWalkerContext));
Index nextSortGroupRefIndex = 0;
walkerContext->repartitionSubquery = false; walkerContext->repartitionSubquery = false;
walkerContext->expressionList = NIL; walkerContext->expressionList = NIL;
Index nextSortGroupRefIndex = 0;
if (CitusIsA(parentNode, MultiTable) && CitusIsA(childNode, MultiCollect)) if (CitusIsA(parentNode, MultiTable) && CitusIsA(childNode, MultiCollect))
{ {
@ -2501,6 +2502,7 @@ TablePartitioningSupportsDistinct(List *tableNodeList, MultiExtendedOp *opNode,
Oid relationId = tableNode->relationId; Oid relationId = tableNode->relationId;
bool tableDistinctSupported = false; bool tableDistinctSupported = false;
char partitionMethod = 0; char partitionMethod = 0;
List *shardList = NIL;
if (relationId == SUBQUERY_RELATION_ID) if (relationId == SUBQUERY_RELATION_ID)
{ {
@ -2508,7 +2510,7 @@ TablePartitioningSupportsDistinct(List *tableNodeList, MultiExtendedOp *opNode,
} }
/* if table has one shard, task results don't overlap */ /* if table has one shard, task results don't overlap */
List *shardList = LoadShardList(relationId); shardList = LoadShardList(relationId);
if (list_length(shardList) == 1) if (list_length(shardList) == 1)
{ {
continue; continue;