mirror of
https://github.com/zeek/zeek.git
synced 2025-10-13 12:08:20 +00:00
Merge remote-tracking branch 'origin/topic/robin/cid-1402823'
- Fixed a reference counting issue * origin/topic/robin/cid-1402823: Fix for CIDs 1402823 and 1394050.
This commit is contained in:
commit
bd6f89da05
4 changed files with 24 additions and 3 deletions
6
CHANGES
6
CHANGES
|
@ -1,4 +1,10 @@
|
|||
|
||||
3.1.0-dev.127 | 2019-09-20 10:40:54 -0700
|
||||
|
||||
* Fix uncaught InterpreterException in Frame cloning (Robin Sommer, Corelight)
|
||||
|
||||
Fix for CIDs 1402823 and 1394050.
|
||||
|
||||
3.1.0-dev.125 | 2019-09-19 16:40:10 -0700
|
||||
|
||||
* Update header include guard in zeek-config.h/bro-config.h (Jon Siwek, Corelight)
|
||||
|
|
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
|||
3.1.0-dev.125
|
||||
3.1.0-dev.127
|
||||
|
|
|
@ -128,7 +128,7 @@ public:
|
|||
/**
|
||||
* Performs a deep copy of all the values in the current frame. If
|
||||
* the frame has a closure the returned frame captures that closure
|
||||
* by reference.. As such, performing a clone operation does not copy
|
||||
* by reference. As such, performing a clone operation does not copy
|
||||
* the values in the closure.
|
||||
*
|
||||
* @return a copy of this frame.
|
||||
|
|
|
@ -218,7 +218,22 @@ bool Trigger::Eval()
|
|||
// An alternative approach to copying the frame would be to deep-copy
|
||||
// the expression itself, replacing all references to locals with
|
||||
// constants.
|
||||
Frame* f = frame->Clone();
|
||||
|
||||
Frame* f = nullptr;
|
||||
|
||||
try
|
||||
{
|
||||
f = frame->Clone();
|
||||
}
|
||||
catch ( InterpreterException& )
|
||||
{
|
||||
// Frame contains values that couldn't be cloned. It's
|
||||
// already been reported, disable trigger.
|
||||
Disable();
|
||||
Unref(this);
|
||||
return false;
|
||||
}
|
||||
|
||||
f->SetTrigger(this);
|
||||
|
||||
Val* v = nullptr;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue