Fixed crash for small batches

Batches that were less than max_threads would cause a crash since it
would attempt to read past the bounds of batchargs.