Fix a bunch of clang reported issues.