Fixed compile error.
Fixed clang warnings.