pit fib small corrections
diff --git a/model/ccnx-fib.cc b/model/ccnx-fib.cc
index 164b46b..f8c5956 100644
--- a/model/ccnx-fib.cc
+++ b/model/ccnx-fib.cc
@@ -27,6 +27,7 @@
 #include "ns3/node.h"
 #include "ns3/assert.h"
 #include "ns3/names.h"
+#include "ns3/log.h"
 
 #define NDN_RTO_ALPHA 0.125
 #define NDN_RTO_BETA 0.25
@@ -95,7 +96,8 @@
 }
 //////////////////////////////////////////////////////////////////////
 //////////////////////////////////////////////////////////////////////
-
+NS_LOG_COMPONENT_DEFINE ("CcnxFib");
+    
 using namespace __ccnx_private;
 
 TypeId 
@@ -147,16 +149,18 @@
 void
 CcnxFibEntry::AddOrUpdateRoutingMetric::operator () (CcnxFibEntry &entry)
 {
+  NS_LOG_FUNCTION(this);
+  NS_ASSERT_MSG (m_face != NULL, "Trying to Add or Update NULL face");
+
   CcnxFibFaceMetricByFace::type::iterator record = entry.m_faces.get<i_face> ().find (m_face);
   if (record == entry.m_faces.get<i_face> ().end ())
     {
       entry.m_faces.insert (CcnxFibFaceMetric (m_face, m_metric));
     }
   else
-    {
+  {
       entry.m_faces.modify (record, ChangeMetric (m_metric));
     }
-  
   // reordering random access index same way as by metric index
   entry.m_faces.get<i_nth> ().rearrange (entry.m_faces.get<i_metric> ().begin ());
 }
@@ -221,14 +225,17 @@
 CcnxFib::Add (const CcnxNameComponents &prefix, Ptr<CcnxFace> face, int32_t metric)
 {
 // CcnxFibFaceMetric
+  NS_LOG_FUNCTION(this << prefix << face << metric);
   CcnxFibEntryContainer::type::iterator entry = find (prefix);
   if (entry == end ())
     {
       entry = insert (end (), CcnxFibEntry (prefix));
       // insert new
     }
-  modify (entry, CcnxFibEntry::AddOrUpdateRoutingMetric (face, metric));
 
+  NS_ASSERT_MSG (face != NULL, "Trying to modify NULL face");
+  modify (entry, CcnxFibEntry::AddOrUpdateRoutingMetric (face, metric));
+    
   return entry;
 }