lsa: leverage class hierarchy when serializing.
refs: #4354
Change-Id: Ia3e79694c785b208184137d8ef0813629d61cc83
diff --git a/src/lsdb.cpp b/src/lsdb.cpp
index 2661813..327c3f1 100644
--- a/src/lsdb.cpp
+++ b/src/lsdb.cpp
@@ -1097,7 +1097,7 @@
NameLsa* nameLsa = m_nlsr.getLsdb().findNameLsa(lsaKey);
if (nameLsa != 0) {
if (nameLsa->getLsSeqNo() == seqNo) {
- std::string content = nameLsa->getData();
+ std::string content = nameLsa->serialize();
putLsaData(interest,content);
// increment SENT_NAME_LSA_DATA
lsaIncrementSignal(Statistics::PacketType::SENT_NAME_LSA_DATA);
@@ -1131,7 +1131,7 @@
AdjLsa* adjLsa = m_nlsr.getLsdb().findAdjLsa(lsaKey);
if (adjLsa != 0) {
if (adjLsa->getLsSeqNo() == seqNo) {
- std::string content = adjLsa->getData();
+ std::string content = adjLsa->serialize();
putLsaData(interest,content);
// increment SENT_ADJ_LSA_DATA
lsaIncrementSignal(Statistics::PacketType::SENT_ADJ_LSA_DATA);
@@ -1165,7 +1165,7 @@
CoordinateLsa* corLsa = m_nlsr.getLsdb().findCoordinateLsa(lsaKey);
if (corLsa != 0) {
if (corLsa->getLsSeqNo() == seqNo) {
- std::string content = corLsa->getData();
+ std::string content = corLsa->serialize();
putLsaData(interest,content);
// increment SENT_COORD_LSA_DATA
lsaIncrementSignal(Statistics::PacketType::SENT_COORD_LSA_DATA);