Fix casings and compiler warnings