face-management-protocol: Fixing small bug with ForwardingEntry
The daemon always expects Prefix entry, even though it is defined
optional in the protocol.
Change-Id: I4ade13897af8e47944be2384a2fc116959e50d15
diff --git a/include/ndn-cpp/forwarding-entry.hpp b/include/ndn-cpp/forwarding-entry.hpp
index e9a3f47..182dc38 100644
--- a/include/ndn-cpp/forwarding-entry.hpp
+++ b/include/ndn-cpp/forwarding-entry.hpp
@@ -108,11 +108,8 @@
}
// Name
- if (!prefix_.empty())
- {
- wire_.push_back
- (prefix_.wireEncode());
- }
+ wire_.push_back
+ (prefix_.wireEncode());
// FaceID
if (faceId_ >= 0)
@@ -203,10 +200,7 @@
}
// Name
- if (!entry.getPrefix().empty())
- {
- os << "Prefix:" << entry.getPrefix() << ", ";
- }
+ os << "Prefix:" << entry.getPrefix() << ", ";
// FaceID
if (entry.getFaceId() >= 0)