[Zeek] Sorting a vector of intervals.

Tomek Koziak ttomek.koziak at gmail.com
Sat May 16 11:55:13 PDT 2020

Hi All,
When I try to run the following code

event zeek_init()
local v: vector of interval = vector(1min,2min,1min,4min,6min,1min);
local vo : vector of interval = sort(v);
    for (i in vo){
    print vo[i];

I get the expected output by as well I obtain the following error:
line 4: comparison function required for sort() with non-integral types
(sort(v)) fatal error: errors occurred while initializing

I have followed the documentation.
But I quite don't understand the part about the comparison function as a
second argument. What parameter should be placed as a second argument?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ICSI.Berkeley.EDU/pipermail/zeek/attachments/20200516/7fa6edb2/attachment.html 

More information about the Zeek mailing list