From: tho Date: Thu, 2 Aug 2007 09:36:15 +0000 (+0000) Subject: changed font for dot graphs to Verdana X-Git-Url: http://g0dil.de/git?a=commitdiff_plain;h=ff5c294bc663a5927baa07a1d342dd077b42f1a6;p=senf.git changed font for dot graphs to Verdana git-svn-id: https://svn.berlios.de/svnroot/repos/senf/trunk@372 270642c3-0616-0410-b53a-bc976706d245 --- diff --git a/Examples/DVBAdapter/ULEdec.cc b/Examples/DVBAdapter/ULEdec.cc index 5b3e2f8..bbc4ed8 100644 --- a/Examples/DVBAdapter/ULEdec.cc +++ b/Examples/DVBAdapter/ULEdec.cc @@ -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: diff --git a/doclib/dot-munge.pl b/doclib/dot-munge.pl index dcebfc8..7cc72ca 100755 --- a/doclib/dot-munge.pl +++ b/doclib/dot-munge.pl @@ -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)