Minor changes to main.cpp