mirror of
https://github.com/zeek/zeek.git
synced 2025-10-10 18:48:20 +00:00
Frame: use class IntrusivePtr
This commit is contained in:
parent
79570fdfd6
commit
78e736621c
4 changed files with 17 additions and 37 deletions
|
@ -337,7 +337,7 @@ IntrusivePtr<Val> BroFunc::Call(val_list* args, Frame* parent) const
|
|||
// Hand down any trigger.
|
||||
if ( parent )
|
||||
{
|
||||
f->SetTrigger(parent->GetTrigger());
|
||||
f->SetTrigger({NewRef{}, parent->GetTrigger()});
|
||||
f->SetCall(parent->GetCall());
|
||||
}
|
||||
|
||||
|
@ -525,7 +525,7 @@ bool BroFunc::UpdateClosure(const broker::vector& data)
|
|||
if ( ! result.first )
|
||||
return false;
|
||||
|
||||
Frame* new_closure = result.second;
|
||||
auto &new_closure = result.second;
|
||||
if ( new_closure )
|
||||
new_closure->SetFunction(this);
|
||||
|
||||
|
@ -533,7 +533,7 @@ bool BroFunc::UpdateClosure(const broker::vector& data)
|
|||
Unref(closure);
|
||||
|
||||
weak_closure_ref = false;
|
||||
closure = new_closure;
|
||||
closure = new_closure.release();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue