changed font for dot graphs to Verdana
tho [Thu, 2 Aug 2007 09:36:15 +0000 (09:36 +0000)]
git-svn-id: https://svn.berlios.de/svnroot/repos/senf/trunk@372 270642c3-0616-0410-b53a-bc976706d245

Examples/DVBAdapter/ULEdec.cc
doclib/dot-munge.pl

index 5b3e2f8..bbc4ed8 100644 (file)
@@ -144,7 +144,7 @@ void ULEdec::handleTSPacket(senf::TransportPacket ts_packet)
     } else {
         // a PUSI value of 1 indicates the presence of a Payload Pointer.
         unsigned char payload_pointer = *payload_start++;
-        if (payload_pointer>181) {
+        if (payload_pointer > 181) {
             std::cerr << "invalid payload_pointer\n";
             return;
         }
@@ -155,7 +155,18 @@ void ULEdec::handleTSPacket(senf::TransportPacket ts_packet)
             this->snduPacket.dump(std::cout);
             break;
         case Reassembly:
-            readContSNDUPacket( payload_start, payload_end );
+            // Reassembly Payload Pointer Checking
+            unsigned char sdnu_bytes_left = std::distance(
+                    this->snduPacketData_iter, this->snduPacket.data().end() );
+            if (sdnu_bytes_left != payload_pointer) {
+                // delimiting error
+                std::cerr << "delimiting error\n";
+                payload_start += payload_pointer;
+            } else {
+                readContSNDUPacket( payload_start, payload_end );
+                BOOST_ASSERT( this->snduPacketData_iter == this->snduPacket.data().end() );
+            }
+            readNewSNDUPacket( payload_start, payload_end );
         }       
     }
 
@@ -186,10 +197,11 @@ ULEdec::iterator ULEdec::readNewSNDUPacket(iterator i_start, iterator i_end)
     this->snduPacket->d_bit() = dbit;
     this->snduPacket->length() = sndu_length;
     this->snduPacketData_iter = this->snduPacket.data().begin() + 2;
+    this->priv_sndu_type_1 = false;
     
     switch (std::distance(i_start, i_end)) {
     case 1:
-        this->priv_sndu_type_1 = true;;
+        this->priv_sndu_type_1 = true;
         this->snduPacket->type() = *i_start++;
         this->snduPacketData_iter++;
     case 0:
index dcebfc8..7cc72ca 100755 (executable)
@@ -2,8 +2,8 @@
 
 # Reduce font size
 s/fontsize=10/fontsize=8/g; 
-s/fontname="FreeSans.ttf"/fontname="Bitstream Vera Sans Mono"/g;
-##s/fontname="FreeSans.ttf"/fontname="Verdana"/g;
+##s/fontname="FreeSans.ttf"/fontname="Bitstream Vera Sans Mono"/g;
+s/fontname="FreeSans.ttf"/fontname="Verdana"/g;
 ##s/fontname="FreeSans.ttf"/fontname="Lucida Sans Typewriter"/g;
 
 # Wrap long labels (templates)