mirror of
https://github.com/zeek/zeek.git
synced 2025-10-17 14:08:20 +00:00
Pre-allocate and re-use Vals for bool, int, count, enum and empty string
This commit is contained in:
parent
dcbef9cbe3
commit
2982765128
136 changed files with 1859 additions and 1811 deletions
|
@ -13,7 +13,7 @@ function FileExtract::__set_limit%(file_id: string, args: any, n: count%): bool
|
|||
RecordVal* rv = args->AsRecordVal()->CoerceTo(AnalyzerArgs);
|
||||
bool result = file_mgr->SetExtractionLimit(file_id->CheckString(), rv, n);
|
||||
Unref(rv);
|
||||
return new Val(result, TYPE_BOOL);
|
||||
return val_mgr->GetBool(result);
|
||||
%}
|
||||
|
||||
module GLOBAL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue