Merge pull request #4974 from citusdata/minor_b_fix

Remove wrong PG_USED_FOR_ASSERTS_ONLY
pull/4927/head^2
Önder Kalacı 2021-05-11 14:13:52 +02:00 committed by GitHub
commit fa61eda7b9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 2 deletions

View File

@ -4457,8 +4457,6 @@ ScheduleNextPlacementExecution(TaskPlacementExecution *placementExecution, bool
executionOrder == EXECUTION_ORDER_SEQUENTIAL) executionOrder == EXECUTION_ORDER_SEQUENTIAL)
{ {
TaskPlacementExecution *nextPlacementExecution = NULL; TaskPlacementExecution *nextPlacementExecution = NULL;
int placementExecutionCount PG_USED_FOR_ASSERTS_ONLY =
shardCommandExecution->placementExecutionCount;
/* find a placement execution that is not yet marked as failed */ /* find a placement execution that is not yet marked as failed */
do { do {
@ -4469,6 +4467,7 @@ ScheduleNextPlacementExecution(TaskPlacementExecution *placementExecution, bool
* If all tasks failed then we should already have errored out. * If all tasks failed then we should already have errored out.
* Still, be defensive and throw error instead of crashes. * Still, be defensive and throw error instead of crashes.
*/ */
int placementExecutionCount = shardCommandExecution->placementExecutionCount;
if (nextPlacementExecutionIndex >= placementExecutionCount) if (nextPlacementExecutionIndex >= placementExecutionCount)
{ {
WorkerPool *workerPool = placementExecution->workerPool; WorkerPool *workerPool = placementExecution->workerPool;