From 9b600ed96e7fd5143192d38efae095ebd0277bf9 Mon Sep 17 00:00:00 2001
From: Christophe Geuzaine <cgeuzaine@ulg.ac.be>
Date: Thu, 16 Jan 2014 16:09:05 +0000
Subject: [PATCH] fix destructor

---
 Common/onelab.h            | 1 +
 utils/solvers/c++/onelab.h | 1 +
 2 files changed, 2 insertions(+)

diff --git a/Common/onelab.h b/Common/onelab.h
index 0f77d8e000..c7a3d8a7c5 100644
--- a/Common/onelab.h
+++ b/Common/onelab.h
@@ -1180,6 +1180,7 @@ namespace onelab{
     virtual ~remoteNetworkClient()
     {
       if(_gmshClient){
+        _waitOnSubClients();
         _gmshClient->Stop();
         _gmshClient->Disconnect();
         delete _gmshClient;
diff --git a/utils/solvers/c++/onelab.h b/utils/solvers/c++/onelab.h
index 0f77d8e000..c7a3d8a7c5 100644
--- a/utils/solvers/c++/onelab.h
+++ b/utils/solvers/c++/onelab.h
@@ -1180,6 +1180,7 @@ namespace onelab{
     virtual ~remoteNetworkClient()
     {
       if(_gmshClient){
+        _waitOnSubClients();
         _gmshClient->Stop();
         _gmshClient->Disconnect();
         delete _gmshClient;
-- 
GitLab