Minor changes to main.