refactor: packet dump utils
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
#include "packet_def.h"
|
||||
#include "packet_ldbc.h"
|
||||
#include "packet_parse.h"
|
||||
#include "packet_dump.h"
|
||||
|
||||
/******************************************************************************
|
||||
* [Protocols in frame: eth:ethertype:ip:ipv6:tcp]
|
||||
@@ -76,7 +77,7 @@ TEST(PACKET_LDBC, HASH_VALUE)
|
||||
const char *payload = packet_parse(&handler, (const char *)data, sizeof(data));
|
||||
EXPECT_TRUE(payload != nullptr);
|
||||
EXPECT_TRUE((char *)payload - (char *)&data == 106);
|
||||
packet_print(&handler);
|
||||
packet_dump_stdio(&handler);
|
||||
|
||||
// buffer: "2001:da8:200:900e:200:5efe:d24d:58a3 0 2600:140e:6::1702:1058 0"
|
||||
// buffer: "210.77.88.163 0 59.66.4.50 0"
|
||||
|
||||
Reference in New Issue
Block a user