Fixed bug with log file.