Fix compiling errors