mirror of
https://github.com/zeek/zeek.git
synced 2025-10-17 14:08:20 +00:00
Merge remote branch 'origin/topic/robin/logging-internals'
Includes some additional cleanup.
This commit is contained in:
commit
13a492091f
119 changed files with 5266 additions and 183 deletions
|
@ -135,6 +135,26 @@ function sort_string_array%(a: string_array%): string_array
|
|||
vs_to_string_array(vs, b, 1, n);
|
||||
return b;
|
||||
%}
|
||||
|
||||
function join_string_vec%(vec: string_vec, sep: string%): string
|
||||
%{
|
||||
ODesc d;
|
||||
VectorVal *v = vec->AsVectorVal();
|
||||
|
||||
for ( unsigned i = 0; i < v->Size(); ++i )
|
||||
{
|
||||
if ( i > 0 )
|
||||
d.Add(sep->CheckString(), 0);
|
||||
|
||||
v->Lookup(i+1)->Describe(&d);
|
||||
}
|
||||
|
||||
BroString* s = new BroString(1, d.TakeBytes(), d.Len());
|
||||
s->SetUseFreeToDelete(true);
|
||||
|
||||
return new StringVal(s);
|
||||
%}
|
||||
|
||||
|
||||
function edit%(arg_s: string, arg_edit_char: string%): string
|
||||
%{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue