diff --git a/opm/autodiff/FlowMain.hpp b/opm/autodiff/FlowMain.hpp index b61605f58..57ed49e0e 100644 --- a/opm/autodiff/FlowMain.hpp +++ b/opm/autodiff/FlowMain.hpp @@ -373,7 +373,11 @@ namespace Opm } else { baseName = path(fpath.filename()).string(); } - logFile_ = baseName + ".PRT"; + if (param_.has("output_dir")) { + logFile_ = output_dir_ + "/" + baseName + ".PRT"; + } else { + logFile_ = baseName + ".PRT"; + } // Create Parser ParserPtr parser(new Parser()); {