Handling all errors when opening config file added. Fixes #2