bugfixes for opening config files