Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
senf
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
wiback
senf
Commits
2f03b997
Commit
2f03b997
authored
17 years ago
by
tho
Browse files
Options
Downloads
Patches
Plain Diff
houston, we have a problem...
parent
aeb9f63c
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
Packets/MPEGDVBBundle/TLVPacket.cc
+7
-16
7 additions, 16 deletions
Packets/MPEGDVBBundle/TLVPacket.cc
Packets/MPEGDVBBundle/TLVPacket.hh
+3
-3
3 additions, 3 deletions
Packets/MPEGDVBBundle/TLVPacket.hh
Packets/MPEGDVBBundle/TLVPacket.test.cc
+3
-0
3 additions, 0 deletions
Packets/MPEGDVBBundle/TLVPacket.test.cc
with
13 additions
and
19 deletions
Packets/MPEGDVBBundle/TLVPacket.cc
+
7
−
16
View file @
2f03b997
...
@@ -21,15 +21,13 @@
...
@@ -21,15 +21,13 @@
// 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
// 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
/** \file
/** \file
\brief
DSMCCSection
non-inline non-template implementation */
\brief
TLVPacket
non-inline non-template implementation */
#include
"TLVPacket.hh"
#include
"TLVPacket.hh"
//#include "TLVPacket.ih"
//#include "TLVPacket.ih"
// Custom includes
// Custom includes
#include
<iomanip>
#include
<iomanip>
#include
"../../Utils/hexdump.hh"
#include
"../../Packets/DefaultBundle/EthernetPacket.hh"
#define prefix_
#define prefix_
...
@@ -39,14 +37,11 @@
...
@@ -39,14 +37,11 @@
prefix_
senf
::
PacketParserBase
::
size_type
senf
::
Parse_TLVPacket
::
bytes
()
prefix_
senf
::
PacketParserBase
::
size_type
senf
::
Parse_TLVPacket
::
bytes
()
const
const
{
{
//#include <iostream>
// std::cout << "XX: " << unsigned( 4 + senf::bytes( length() ) ) << "\n";
return
4
+
senf
::
bytes
(
length
()
);
return
4
+
senf
::
bytes
(
length
()
);
}
}
//prefix_ void senf::TLVPacketType::init(packet p)
//{
// p->init();
//}
prefix_
void
senf
::
TLVPacketType
::
dump
(
packet
p
,
std
::
ostream
&
os
)
prefix_
void
senf
::
TLVPacketType
::
dump
(
packet
p
,
std
::
ostream
&
os
)
{
{
os
<<
"TLVPacket:
\n
"
os
<<
"TLVPacket:
\n
"
...
@@ -55,15 +50,11 @@ prefix_ void senf::TLVPacketType::dump(packet p, std::ostream & os)
...
@@ -55,15 +50,11 @@ prefix_ void senf::TLVPacketType::dump(packet p, std::ostream & os)
<<
" length: "
<<
unsigned
(
p
->
length
())
<<
"
\n
"
;
<<
" length: "
<<
unsigned
(
p
->
length
())
<<
"
\n
"
;
}
}
prefix_
senf
::
PacketParserBase
::
size_type
senf
::
TLVPacketType
::
initSize
()
//
prefix_ senf::PacketParserBase::size_type senf::TLVPacketType::initSize()
{
//
{
return
4
+
1
;
//
return 4 + 1;
}
//
}
prefix_
senf
::
PacketParserBase
::
size_type
senf
::
TLVPacketType
::
initHeadSize
()
{
return
4
+
1
;
}
///////////////////////////////cc.e////////////////////////////////////////
///////////////////////////////cc.e////////////////////////////////////////
#undef prefix_
#undef prefix_
...
...
This diff is collapsed.
Click to expand it.
Packets/MPEGDVBBundle/TLVPacket.hh
+
3
−
3
View file @
2f03b997
...
@@ -149,12 +149,12 @@ namespace senf {
...
@@ -149,12 +149,12 @@ namespace senf {
using
mixin
::
nextPacketRange
;
using
mixin
::
nextPacketRange
;
using
mixin
::
init
;
using
mixin
::
init
;
using
mixin
::
initSize
;
static
void
dump
(
packet
p
,
std
::
ostream
&
os
);
static
void
dump
(
packet
p
,
std
::
ostream
&
os
);
static
PacketParserBase
::
size_type
initSize
();
//
static PacketParserBase::size_type initSize();
static
PacketParserBase
::
size_type
initHeadSize
();
//
static PacketParserBase::size_type initHeadSize();
};
};
typedef
TLVPacketType
::
packet
TLVPacket
;
typedef
TLVPacketType
::
packet
TLVPacket
;
...
...
This diff is collapsed.
Click to expand it.
Packets/MPEGDVBBundle/TLVPacket.test.cc
+
3
−
0
View file @
2f03b997
...
@@ -28,6 +28,7 @@
...
@@ -28,6 +28,7 @@
// Custom includes
// Custom includes
#include
"TLVPacket.hh"
#include
"TLVPacket.hh"
#include
<senf/Packets.hh>
#include
<senf/Packets.hh>
#include
<senf/Utils/hexdump.hh>
#include
<boost/test/auto_unit_test.hpp>
#include
<boost/test/auto_unit_test.hpp>
#include
<boost/test/test_tools.hpp>
#include
<boost/test/test_tools.hpp>
...
@@ -55,6 +56,8 @@ BOOST_AUTO_UNIT_TEST(tlvPacket_parse_packet_with_extended_length)
...
@@ -55,6 +56,8 @@ BOOST_AUTO_UNIT_TEST(tlvPacket_parse_packet_with_extended_length)
BOOST_CHECK_EQUAL
(
p
->
length
(),
0x0Au
);
BOOST_CHECK_EQUAL
(
p
->
length
(),
0x0Au
);
senf
::
PacketData
&
p_value
(
p
.
next
().
data
());
senf
::
PacketData
&
p_value
(
p
.
next
().
data
());
senf
::
hexdump
(
p_value
.
begin
(),
p_value
.
end
(),
std
::
cout
);
// BOOST_CHECK_EQUAL( p_value.size(), 0x0Au);
// BOOST_CHECK_EQUAL( p_value.size(), 0x0Au);
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment