/src/zeek/build/src/cluster/websocket/events.bif.cc
Line | Count | Source (jump to first uncovered line) |
1 | | // This file was automatically generated by bifcl from /src/zeek/src/cluster/websocket/events.bif (plugin mode). |
2 | | |
3 | | |
4 | | #include "events.bif.h" |
5 | | #include "zeek/Func.h" |
6 | | |
7 | | namespace Cluster { zeek::EventHandlerPtr websocket_client_added; } |
8 | | void zeek::BifEvent::Cluster::enqueue_websocket_client_added(zeek::analyzer::Analyzer* analyzer, zeek::IntrusivePtr<zeek::Val> endpoint, zeek::IntrusivePtr<zeek::Val> subscriptions) |
9 | 0 | { |
10 | | // Note that it is intentional that here we do not |
11 | | // check if ::Cluster::websocket_client_added is NULL, which should happen *before* |
12 | | // zeek::BifEvent::Cluster::enqueue_websocket_client_added is called to avoid unnecessary Val |
13 | | // allocation. |
14 | |
|
15 | 0 | zeek::event_mgr.Enqueue(::Cluster::websocket_client_added, zeek::Args{ |
16 | 0 | std::move(endpoint), |
17 | 0 | std::move(subscriptions), |
18 | 0 | }, |
19 | 0 | zeek::util::detail::SOURCE_LOCAL, analyzer ? analyzer->GetID() : 0); |
20 | 0 | } |
21 | | |
22 | | namespace Cluster { zeek::EventHandlerPtr websocket_client_lost; } |
23 | | void zeek::BifEvent::Cluster::enqueue_websocket_client_lost(zeek::analyzer::Analyzer* analyzer, zeek::IntrusivePtr<zeek::Val> endpoint, zeek_uint_t code, zeek::IntrusivePtr<zeek::StringVal> reason) |
24 | 0 | { |
25 | | // Note that it is intentional that here we do not |
26 | | // check if ::Cluster::websocket_client_lost is NULL, which should happen *before* |
27 | | // zeek::BifEvent::Cluster::enqueue_websocket_client_lost is called to avoid unnecessary Val |
28 | | // allocation. |
29 | |
|
30 | 0 | zeek::event_mgr.Enqueue(::Cluster::websocket_client_lost, zeek::Args{ |
31 | 0 | std::move(endpoint), |
32 | 0 | zeek::val_mgr->Count(code), |
33 | 0 | std::move(reason), |
34 | 0 | }, |
35 | 0 | zeek::util::detail::SOURCE_LOCAL, analyzer ? analyzer->GetID() : 0); |
36 | 0 | } |
37 | | |