1) Fixed a bug where -o option was not working correctly