fix more formatting and compiler warnings