mirror of
https://github.com/zeek/zeek.git
synced 2025-10-03 23:28:20 +00:00
Deprecate global type pointers in NetVar.h
There's analogous IntrusivePtrs in zeek::vars
This commit is contained in:
parent
4351a26710
commit
c0986f0739
51 changed files with 451 additions and 224 deletions
|
@ -107,7 +107,7 @@ static RecordVal* build_syn_packet_val(bool is_orig, const IP_Hdr* ip,
|
|||
options += opt_len;
|
||||
}
|
||||
|
||||
RecordVal* v = new RecordVal(SYN_packet);
|
||||
RecordVal* v = new RecordVal(zeek::vars::SYN_packet);
|
||||
|
||||
v->Assign(0, val_mgr->Bool(is_orig));
|
||||
v->Assign(1, val_mgr->Bool(int(ip->DF())));
|
||||
|
@ -1421,7 +1421,7 @@ int TCP_Analyzer::ParseTCPOptions(const struct tcphdr* tcp, bool is_orig)
|
|||
{
|
||||
auto p = reinterpret_cast<const uint32_t*>(o + 2);
|
||||
auto num_pointers = (length - 2) / 4;
|
||||
auto vt = zeek::lookup_type<VectorType>("index_vec");
|
||||
auto vt = zeek::vars::index_vec;
|
||||
auto sack = make_intrusive<VectorVal>(std::move(vt));
|
||||
|
||||
for ( auto i = 0; i < num_pointers; ++i )
|
||||
|
@ -2077,7 +2077,7 @@ bool TCPStats_Endpoint::DataSent(double /* t */, uint64_t seq, int len, int capl
|
|||
|
||||
RecordVal* TCPStats_Endpoint::BuildStats()
|
||||
{
|
||||
RecordVal* stats = new RecordVal(endpoint_stats);
|
||||
RecordVal* stats = new RecordVal(zeek::vars::endpoint_stats);
|
||||
|
||||
stats->Assign(0, val_mgr->Count(num_pkts));
|
||||
stats->Assign(1, val_mgr->Count(num_rxmit));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue