fix issue where log file cannot be created due to invalid name/path