summaryrefslogtreecommitdiffstats
path: root/src/bp_sim.cpp
diff options
context:
space:
mode:
authorHanoh Haim <hhaim@cisco.com>2016-04-11 16:41:24 +0300
committerHanoh Haim <hhaim@cisco.com>2016-04-11 16:41:24 +0300
commit145a106abceaeb10f62dd40bc11010932f4b9576 (patch)
tree98ef8b22154e9db4bb964a49fdc425e9b0c64f4d /src/bp_sim.cpp
parentf7d55aa327c0c6f721dee05f2f32a54d6ccf51cc (diff)
parentaf49c70aaaecb897c7d3b4bddb18f504d32b0546 (diff)
Merge remove old code
Diffstat (limited to 'src/bp_sim.cpp')
-rwxr-xr-xsrc/bp_sim.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/bp_sim.cpp b/src/bp_sim.cpp
index 2732548c..2c122e72 100755
--- a/src/bp_sim.cpp
+++ b/src/bp_sim.cpp
@@ -3652,10 +3652,15 @@ int CNodeGenerator::flush_file(dsec_t max_time,
if ( unlikely( node_sl->is_mask_for_free() ) ) {
thread->free_node(node);
} else {
- node_sl->handle(thread);
+ /* count before handle - node might be destroyed */
#ifdef TREX_SIM
update_stl_stats(node_sl);
+ #endif
+
+ node_sl->handle(thread);
+
+ #ifdef TREX_SIM
if (has_limit_reached()) {
thread->m_stateless_dp_info.stop_traffic(node_sl->get_port_id(), false, 0);
}