Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[pvs] Expression 'req' is always true.
[simgrid.git] / src / mc / checker / SafetyChecker.cpp
index 9f9716fe6f156be673b263e1dfd299d3e3bbc585..feb44630646dc1d2bd43af8ebcae1f43eab0e7ec 100644 (file)
@@ -63,8 +63,7 @@ std::vector<std::string> SafetyChecker::get_textual_trace() // override
   for (auto const& state : stack_) {
     int value         = state->transition_.argument_;
     smx_simcall_t req = &state->executed_req_;
-    if (req)
-      trace.push_back(request_to_string(req, value, RequestType::executed));
+    trace.push_back(request_to_string(req, value, RequestType::executed));
   }
   return trace;
 }
@@ -192,7 +191,7 @@ void SafetyChecker::backtrack()
     stack_.pop_back();
     if (reductionMode_ == ReductionMode::dpor) {
       smx_simcall_t req = &state->internal_req_;
-      if (req->call_ == SIMCALL_MUTEX_LOCK || req->call_ == SIMCALL_MUTEX_TRYLOCK)
+      if (req->call_ == simix::Simcall::MUTEX_LOCK || req->call_ == simix::Simcall::MUTEX_TRYLOCK)
         xbt_die("Mutex is currently not supported with DPOR,  use --cfg=model-check/reduction:none");
 
       const kernel::actor::ActorImpl* issuer = MC_smx_simcall_get_issuer(req);