Skip to content

Commit 2015694

Browse files
committed
Adjust Stats plugin
1 parent f45a7e7 commit 2015694

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

process/stats.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,21 +82,21 @@ ProcessPlugin *StatsPlugin::copy()
8282
return new StatsPlugin(*this);
8383
}
8484

85-
int StatsPlugin::post_create(Flow &rec, const Packet &pkt)
85+
ProcessPlugin::FlowAction StatsPlugin::post_create(Flow &rec, const Packet &pkt)
8686
{
8787
m_packets += 1;
8888
m_new_flows += 1;
8989
m_flows_in_cache += 1;
9090
check_timestamp(pkt);
91-
return 0;
91+
return ProcessPlugin::FlowAction::GET_ALL_DATA;
9292
}
9393

94-
int StatsPlugin::post_update(Flow &rec, const Packet &pkt)
94+
ProcessPlugin::FlowAction StatsPlugin::post_update(Flow &rec, const Packet &pkt)
9595
{
9696
m_packets += 1;
9797
m_cache_hits += 1;
9898
check_timestamp(pkt);
99-
return 0;
99+
return ProcessPlugin::FlowAction::GET_ALL_DATA;
100100
}
101101

102102
void StatsPlugin::pre_export(Flow &rec)

process/stats.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,8 @@ class StatsPlugin : public ProcessPlugin
7171
std::string get_name() const { return "stats"; }
7272
ProcessPlugin *copy();
7373

74-
int post_create(Flow &rec, const Packet &pkt);
75-
int post_update(Flow &rec, const Packet &pkt);
74+
ProcessPlugin::FlowAction post_create(Flow &rec, const Packet &pkt);
75+
ProcessPlugin::FlowAction post_update(Flow &rec, const Packet &pkt);
7676
void pre_export(Flow &rec);
7777
void finish(bool print_stats);
7878

0 commit comments

Comments
 (0)