Several minor fixes.