diff --git a/opm/simulators/utils/ParallelRestart.cpp b/opm/simulators/utils/ParallelRestart.cpp index 6bef3d885..888619576 100644 --- a/opm/simulators/utils/ParallelRestart.cpp +++ b/opm/simulators/utils/ParallelRestart.cpp @@ -887,12 +887,14 @@ void unpack(RestartValue& data, std::vector& buffer, int& position, unpack(data.extra, buffer, position, comm); } -void unpack(Opm::time_point& data, std::vector& buffer, int& position, +void unpack([[maybe_unused]] Opm::time_point& data, std::vector& buffer, int& position, Dune::MPIHelper::MPICommunicator comm) { std::time_t tp; unpack(tp, buffer, position, comm); +#if HAVE_MPI data = Opm::TimeService::from_time_t(tp); +#endif }