Fix a few problems.