summaryrefslogtreecommitdiffstats
path: root/src/timer_wheel_pq.cpp
diff options
context:
space:
mode:
authorimarom <imarom@cisco.com>2015-09-03 05:16:12 +0300
committerimarom <imarom@cisco.com>2015-09-03 05:16:12 +0300
commit1912c95b5480cd601581a00645bb2e75e9c6e7a3 (patch)
tree3ddf98b540677f296f9da7daf9c1e14d0970cc05 /src/timer_wheel_pq.cpp
parent6669a4dd3176e21ef8e99fc4a90ecd7a42566be9 (diff)
parent463cb7c212e927a732fb5b702a288a06550c5eb8 (diff)
Merge branch 'master' into rpc
Diffstat (limited to 'src/timer_wheel_pq.cpp')
-rwxr-xr-xsrc/timer_wheel_pq.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/timer_wheel_pq.cpp b/src/timer_wheel_pq.cpp
index 172d061e..bb480abd 100755
--- a/src/timer_wheel_pq.cpp
+++ b/src/timer_wheel_pq.cpp
@@ -169,11 +169,14 @@ bool CTimerWheel::handle(){
assert(timer->m_flow);
CFlowTimerHandle * flow =timer->m_flow;
m_st_handle++;
+
+ timer->m_flow=0;/* stop the timer */
+ flow->m_timer=0;
+
if ( flow->m_callback ){
flow->m_callback(flow);
}
- timer->m_flow=0;/* stop the timer */
- flow->m_timer=0;
+
m_pq.pop();
m_st_free++;
delete timer;