Corrections to commit dbbd78e2 Index into array was using global task count rather than local task count