improve print output
authorMathieu Lacage <mathieu.lacage@sophia.inria.fr>
Wed, 08 Aug 2007 11:20:09 +0200
changeset 1243 c1d23e1b5891
parent 1242 ec55d8913759
child 1244 9ee2a9242c10
improve print output
samples/main-packet-tag.cc
--- a/samples/main-packet-tag.cc	Wed Aug 08 11:19:39 2007 +0200
+++ b/samples/main-packet-tag.cc	Wed Aug 08 11:20:09 2007 +0200
@@ -70,7 +70,7 @@
 MyTag::Print (std::ostream &os) const
 {
   // print the content of this tag for Packet::PrintTags
-  os << (uint32_t)m_simpleValue;
+  os << "MyTag=0x" << std::hex << (uint32_t)m_simpleValue << std::dec;
 }
 uint32_t 
 MyTag::GetSerializedSize (void) const
@@ -130,6 +130,7 @@
   NS_ASSERT (tagCopy.GetSimpleValue () == tag.GetSimpleValue ());
 
   aCopy.PrintTags (std::cout);
+  std::cout << std::endl;
 
   return 0;
 }