Stats tree seems to work properly, including pruning of "empty" leaves
diff --git a/model/ccnx-name-components.cc b/model/ccnx-name-components.cc
index a79b6bb..a0a12da 100644
--- a/model/ccnx-name-components.cc
+++ b/model/ccnx-name-components.cc
@@ -50,6 +50,13 @@
is >> *this;
}
+CcnxNameComponents::CcnxNameComponents (const char *prefix)
+{
+ NS_ASSERT (prefix != 0);
+
+ istringstream is (prefix);
+ is >> *this;
+}
const std::list<std::string> &
CcnxNameComponents::GetComponents () const
diff --git a/model/ccnx-name-components.h b/model/ccnx-name-components.h
index eb4f8c1..622f51f 100644
--- a/model/ccnx-name-components.h
+++ b/model/ccnx-name-components.h
@@ -68,6 +68,13 @@
* @param[in] prefix A string representation of a prefix
*/
CcnxNameComponents (const std::string &prefix);
+
+ /**
+ * @brief Constructor
+ * Creates a prefix from the string (string is parsed using operator>>)
+ * @param[in] prefix A string representation of a prefix
+ */
+ CcnxNameComponents (const char *prefix);
/**
* \brief Generic Add method
diff --git a/model/ccnx-pit-entry.cc b/model/ccnx-pit-entry.cc
index 4b075ab..73f966c 100644
--- a/model/ccnx-pit-entry.cc
+++ b/model/ccnx-pit-entry.cc
@@ -41,10 +41,10 @@
Ptr<CcnxFibEntry> fibEntry)
: m_container (container)
, m_prefix (header->GetNamePtr ())
+ , m_fibEntry (fibEntry)
, m_expireTime (Simulator::Now () + (!header->GetInterestLifetime ().IsZero ()?
header->GetInterestLifetime ():
Seconds (1.0)))
- , m_fibEntry (fibEntry)
, m_maxRetxCount (0)
{
// note that if interest lifetime is not set, the behavior is undefined
diff --git a/model/ccnx-pit-entry.h b/model/ccnx-pit-entry.h
index beda5bb..1ccb6b4 100644
--- a/model/ccnx-pit-entry.h
+++ b/model/ccnx-pit-entry.h
@@ -84,7 +84,7 @@
*
* All set-methods are virtual, in case index rearrangement is necessary in the derived classes
*/
-struct CcnxPitEntry : SimpleRefCount<CcnxPitEntry>
+class CcnxPitEntry : public SimpleRefCount<CcnxPitEntry>
{
public:
typedef std::set< CcnxPitEntryIncomingFace > in_container; ///< @brief incoming faces container type