Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Try to tell sonar that the mutex_ cannot be null in is_enabled()
authorMartin Quinson <martin.quinson@ens-rennes.fr>
Thu, 24 Feb 2022 13:41:37 +0000 (14:41 +0100)
committerMartin Quinson <martin.quinson@ens-rennes.fr>
Thu, 24 Feb 2022 13:41:37 +0000 (14:41 +0100)
src/kernel/actor/MutexObserver.cpp

index 4c54def..f6c454f 100644 (file)
@@ -20,6 +20,7 @@ namespace actor {
 MutexObserver::MutexObserver(ActorImpl* actor, mc::Transition::Type type, activity::MutexImpl* mutex)
     : SimcallObserver(actor), type_(type), mutex_(mutex)
 {
+  xbt_assert(mutex_);
 }
 
 void MutexObserver::serialize(std::stringstream& stream) const