More fixes to checkpointing.