mirror of
https://github.com/zeek/zeek.git
synced 2025-10-14 20:48:21 +00:00
New functions Log::disable_stream() and Log::enable_stream().
When disabled, all outout to a stream will be ignored (but no error raised).
This commit is contained in:
parent
88d114053c
commit
4b7c5905f1
6 changed files with 96 additions and 4 deletions
|
@ -19,6 +19,18 @@ function Log::__create_stream%(id: Log::ID, stream: Log::Stream%) : bool
|
|||
return new Val(result, TYPE_BOOL);
|
||||
%}
|
||||
|
||||
function Log::__enable_stream%(id: Log::ID%) : bool
|
||||
%{
|
||||
bool result = log_mgr->EnableStream(id->AsEnumVal());
|
||||
return new Val(result, TYPE_BOOL);
|
||||
%}
|
||||
|
||||
function Log::__disable_stream%(id: Log::ID%) : bool
|
||||
%{
|
||||
bool result = log_mgr->DisableStream(id->AsEnumVal());
|
||||
return new Val(result, TYPE_BOOL);
|
||||
%}
|
||||
|
||||
function Log::__add_filter%(id: Log::ID, filter: Log::Filter%) : bool
|
||||
%{
|
||||
bool result = log_mgr->AddFilter(id->AsEnumVal(), filter->AsRecordVal());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue