face: replace EventEmitter usage with Signal
refs #2300
Change-Id: I17d0d65d2c474b17dd9f23f271a6144b0b4fbc07
diff --git a/daemon/face/face.cpp b/daemon/face/face.cpp
index 7d3c1b7..0adf2ed 100644
--- a/daemon/face/face.cpp
+++ b/daemon/face/face.cpp
@@ -36,10 +36,10 @@
, m_isOnDemand(false)
, m_isFailed(false)
{
- onReceiveInterest += [this](const ndn::Interest&) { ++m_counters.getNInInterests(); };
- onReceiveData += [this](const ndn::Data&) { ++m_counters.getNInDatas(); };
- onSendInterest += [this](const ndn::Interest&) { ++m_counters.getNOutInterests(); };
- onSendData += [this](const ndn::Data&) { ++m_counters.getNOutDatas(); };
+ onReceiveInterest.connect([this] (const ndn::Interest&) { ++m_counters.getNInInterests(); });
+ onReceiveData .connect([this] (const ndn::Data&) { ++m_counters.getNInDatas(); });
+ onSendInterest .connect([this] (const ndn::Interest&) { ++m_counters.getNOutInterests(); });
+ onSendData .connect([this] (const ndn::Data&) { ++m_counters.getNOutDatas(); });
}
Face::~Face()
@@ -120,8 +120,6 @@
m_isFailed = true;
this->onFail(reason);
-
- this->onFail.clear();
}
template<typename FaceTraits>