mirror of
https://github.com/zeek/zeek.git
synced 2025-10-04 15:48:19 +00:00
BIT-1544: allow NULs in file analysis handles
This commit is contained in:
parent
f336c8c710
commit
05b10fe2e7
5 changed files with 22 additions and 5 deletions
|
@ -105,7 +105,9 @@ module GLOBAL;
|
|||
## .. bro:see:: get_file_handle
|
||||
function set_file_handle%(handle: string%): any
|
||||
%{
|
||||
file_mgr->SetHandle(handle->CheckString());
|
||||
auto bytes = reinterpret_cast<const char*>(handle->Bytes());
|
||||
auto h = std::string(bytes, handle->Len());
|
||||
file_mgr->SetHandle(h);
|
||||
return 0;
|
||||
%}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue