In Name::Component.get, set value to 0 for 0 size.
diff --git a/ndn-cpp/name.hpp b/ndn-cpp/name.hpp
index 7079233..fe250ff 100644
--- a/ndn-cpp/name.hpp
+++ b/ndn-cpp/name.hpp
@@ -55,6 +55,8 @@
       componentStruct.valueLength = value_.size(); 
       if (value_.size() > 0)
         componentStruct.value = (unsigned char*)value_.buf();
+      else
+        componentStruct.value = 0;
     }
   
     /**