Fixed bugs in dotMPI and batch allocator.