X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=kernel%2Fsrc%2FbbtkBlackBoxOutputConnector.cxx;h=cdc8f3335f8e38b2aaacc680e4399f51bf5146ca;hb=9d5a41aa77e7749118fc4885f7b26ea25bd90629;hp=d2ee80e74dec872efd777472318e9f46e7dcf3ae;hpb=c2a4b1893412e50a3d9abff221938a2d16c4a7cb;p=bbtk.git diff --git a/kernel/src/bbtkBlackBoxOutputConnector.cxx b/kernel/src/bbtkBlackBoxOutputConnector.cxx index d2ee80e..cdc8f33 100644 --- a/kernel/src/bbtkBlackBoxOutputConnector.cxx +++ b/kernel/src/bbtkBlackBoxOutputConnector.cxx @@ -3,8 +3,8 @@ Program: bbtk Module: $RCSfile: bbtkBlackBoxOutputConnector.cxx,v $ Language: C++ - Date: $Date: 2008/04/09 11:16:57 $ - Version: $Revision: 1.3 $ + Date: $Date: 2008/04/24 10:11:28 $ + Version: $Revision: 1.7 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -37,15 +37,20 @@ namespace bbtk BlackBoxOutputConnector::~BlackBoxOutputConnector() { - bbtkDebugMessageInc("Kernel",9, - "BlackBoxOutputConnector::~BlackBoxOutputConnector()" - <::iterator i; - for (i=mConnection.begin();i!=mConnection.end();++i) - { - delete *i; - } - bbtkDebugDecTab("Kernel",9); + bbtkDebugMessage("Kernel",9, + "==> BlackBoxOutputConnector::~BlackBoxOutputConnector()" + <Check(); - std::vector::iterator i - = find(mConnection.begin(),mConnection.end(),c); + if (!c) + { + bbtkInternalError("BlackBoxOutputConnector::UnsetConnection("<Check(); + //Connection::WeakPointer w(c); + ConnectionVector::iterator i; + // = find(mConnection.begin(),mConnection.end(),c); + for (i=mConnection.begin(); + i!=mConnection.end(); + ++i) + { + if (*i==c) break; + } if (i==mConnection.end()) { bbtkInternalError("BlackBoxOutputConnector::UnsetConnection("<::iterator i; + bbtkDebugMessage("modified",2, + "==> BlackBoxOutputConnector::SetModifiedStatus() [" + <SetModifiedStatus(); } - bbtkDebugDecTab("Process",5); }