summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMauro Sardara <msardara@cisco.com>2020-06-03 23:51:52 +0200
committerMauro Sardara <msardara@cisco.com>2020-06-03 23:51:52 +0200
commit2dcaaefd65f3b515aeda0848ff4e757cf2c4b82d (patch)
tree128ad2c59e0f21e7617114d51f2fd0a1cbc00598
parentf3f4f8cf18bf21c522e73571d183c95ef5dcb33c (diff)
[HICN-623] Initialize all the callbacks before starting a new RTC session.
Signed-off-by: Mauro Sardara <msardara@cisco.com> Change-Id: Ic4b08e7eb0f01c9e5710d4da1ca68c6120dcd57e
-rw-r--r--libtransport/src/protocols/rtc.cc20
-rw-r--r--libtransport/src/protocols/rtc.h2
2 files changed, 2 insertions, 20 deletions
diff --git a/libtransport/src/protocols/rtc.cc b/libtransport/src/protocols/rtc.cc
index 4fb352623..3b10c7467 100644
--- a/libtransport/src/protocols/rtc.cc
+++ b/libtransport/src/protocols/rtc.cc
@@ -52,26 +52,8 @@ int RTCTransportProtocol::start() {
probeRtt();
sentinelTimer();
newRound();
- scheduleNextInterests();
-
- is_first_ = false;
- is_running_ = true;
-
- if (is_async_) {
- portal_->runEventsLoop();
- is_running_ = false;
- }
- return 0;
-}
-
-void RTCTransportProtocol::stop() {
- if (!is_running_) return;
- is_running_ = false;
-
- if (is_async_) {
- portal_->stopEventsLoop();
- }
+ return TransportProtocol::start();
}
void RTCTransportProtocol::resume() {
diff --git a/libtransport/src/protocols/rtc.h b/libtransport/src/protocols/rtc.h
index f15cdd1eb..a12c96b69 100644
--- a/libtransport/src/protocols/rtc.h
+++ b/libtransport/src/protocols/rtc.h
@@ -95,7 +95,7 @@ class RTCTransportProtocol : public TransportProtocol,
int start() override;
- void stop() override;
+ using TransportProtocol::stop;
void resume() override;