Fixed compile error and several warnings