Fixed clang/gcc errors