Repair serious bug with caching (wrong packet was sent from cache)
diff --git a/model/ccnx-l3-protocol.cc b/model/ccnx-l3-protocol.cc
index d216b4f..83ab9d2 100644
--- a/model/ccnx-l3-protocol.cc
+++ b/model/ccnx-l3-protocol.cc
@@ -260,6 +260,11 @@
 void 
 CcnxL3Protocol::Receive (const Ptr<CcnxFace> &face, const Ptr<const Packet> &p)
 {
+  if (!face->IsUp ())
+    return;
+
+  NS_LOG_DEBUG (*p);
+  
   NS_LOG_LOGIC ("Packet from face " << *face << " received on node " <<  m_node->GetId ());
 
   Ptr<Packet> packet = p->Copy (); // give upper layers a rw copy of the packet
@@ -302,6 +307,8 @@
   catch (CcnxUnknownHeaderException)
     {
       NS_ASSERT_MSG (false, "Unknown CCNx header. Should not happen");
+      NS_LOG_ERROR ("Unknown CCNx header. Should not happen");
+      return;
     }
 }
 
@@ -483,7 +490,7 @@
       NS_ASSERT (contentObjectHeader != 0);      
       NS_LOG_LOGIC("Found in cache");
 
-      OnDataDelayed (contentObjectHeader, contentObject, payload);
+      OnDataDelayed (contentObjectHeader, payload, contentObject);
       return;
     }
 
@@ -525,7 +532,7 @@
   bool propagated = m_forwardingStrategy->
     PropagateInterest (pitEntry, incomingFace, header, packet);
 
-  if (isRetransmitted) //give another chance if retransmitted
+  if (!propagated && isRetransmitted) //give another chance if retransmitted
     {
       // increase max number of allowed retransmissions
       m_pit->modify (m_pit->iterator_to (pitEntry),