Some more minor bug fixes.