mirror of
https://github.com/zeek/zeek.git
synced 2025-10-12 03:28:19 +00:00
Remove BroValUnion by hoisting underlying Val subclass values into subclasses
This commit is contained in:
parent
49ca8e2163
commit
7f92a573d2
29 changed files with 632 additions and 512 deletions
|
@ -263,7 +263,7 @@ refine connection KRB_Conn += {
|
|||
rv->Assign(1, zeek::val_mgr->Bool(${msg.ap_options.mutual_required}));
|
||||
|
||||
auto rvticket = proc_ticket(${msg.ticket});
|
||||
auto authenticationinfo = zeek_analyzer()->GetAuthenticationInfo(rvticket->GetField(2)->AsString(), rvticket->GetField(4)->AsString(), rvticket->GetField(3)->AsCount());
|
||||
auto authenticationinfo = zeek_analyzer()->GetAuthenticationInfo(rvticket->GetStringField(2), rvticket->GetStringField(4), rvticket->GetCountField(3));
|
||||
|
||||
if ( authenticationinfo )
|
||||
rvticket->Assign(5, authenticationinfo);
|
||||
|
|
|
@ -176,7 +176,7 @@ bool NFS_Interp::RPC_BuildReply(RPC_CallInfo* c, BifEnum::rpc_status rpc_status,
|
|||
|
||||
case BifEnum::NFS3::PROC_READ:
|
||||
bro_uint_t offset;
|
||||
offset = c->RequestVal()->AsRecordVal()->GetField(1)->AsCount();
|
||||
offset = c->RequestVal()->AsRecordVal()->GetCountField(1);
|
||||
reply = nfs3_read_reply(buf, n, nfs_status, offset);
|
||||
event = nfs_proc_read;
|
||||
break;
|
||||
|
|
|
@ -127,7 +127,7 @@ function get_contents_file%(cid: conn_id, direction: count%): file
|
|||
auto cf = c->GetRootAnalyzer()->GetContentsFile(direction);
|
||||
|
||||
if ( cf )
|
||||
return zeek::make_intrusive<zeek::Val>(std::move(cf));
|
||||
return zeek::make_intrusive<zeek::FileVal>(std::move(cf));
|
||||
}
|
||||
|
||||
// Return some sort of error value.
|
||||
|
@ -136,5 +136,5 @@ function get_contents_file%(cid: conn_id, direction: count%): file
|
|||
else
|
||||
zeek::emit_builtin_error("no contents file for given direction");
|
||||
|
||||
return zeek::make_intrusive<zeek::Val>(zeek::make_intrusive<zeek::File>(stderr, "-", "w"));
|
||||
return zeek::make_intrusive<zeek::FileVal>(zeek::make_intrusive<zeek::File>(stderr, "-", "w"));
|
||||
%}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue