fix some error and warning in LLVM clang compiler