Some inor bug fixes.