fix some c/c++ style warnings