Fix some small issues with local dof indices.