Fix ubsan warning with ZAM and mmdb btest

This commit is contained in:
Tim Wojtulewicz 2024-11-14 13:14:58 -07:00
parent d5c3cdf33a
commit 5ce0f2edb6

View file

@ -45,6 +45,8 @@ event new_packet(c: connection, p: pkt_hdr)
event zeek_init()
{
assert mmdb_open_asn_db(asn_fn);
assert mmdb_open_location_db(city_fn);
if ( ! mmdb_open_asn_db(asn_fn) )
Reporter::fatal("failed to open asn_db " + asn_fn);
if ( ! mmdb_open_location_db(city_fn) )
Reporter::fatal("failed to open location db " + city_fn);
}