asdfuser pushed a commit to branch master.

commit 996c98f36a874cb6646e8247ace14151f381f1b6
Author: Guillaume Friloux <[email protected]>
Date:   Fri May 24 11:51:09 2013 +0200

    Fixes another bug found by Cravix (IRC) where even if data is going over 
the socket, we still timeout the connection if ecore_con_client_timeout_set and 
ecore_con_server_timeout_set are used! This is even a worst bug than the 
previous one. This patch should also be applied and tested on 1.8. Thx Cravix!
---
 src/lib/ecore_con/ecore_con.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/src/lib/ecore_con/ecore_con.c b/src/lib/ecore_con/ecore_con.c
index 7ca77fe..d27e8dd 100644
--- a/src/lib/ecore_con/ecore_con.c
+++ b/src/lib/ecore_con/ecore_con.c
@@ -1379,7 +1379,10 @@ _ecore_con_server_timer_update(Ecore_Con_Server *svr)
         if (svr->disconnect_time > 0)
           {
              if (svr->until_deletion)
-               ecore_timer_interval_set(svr->until_deletion, 
svr->disconnect_time);
+               {
+                  ecore_timer_interval_set(svr->until_deletion, 
svr->disconnect_time);
+                  ecore_timer_reset(svr->until_deletion);
+               }
              else
                svr->until_deletion = ecore_timer_add(svr->disconnect_time, 
(Ecore_Task_Cb)_ecore_con_server_timer, svr);
           }
@@ -1416,7 +1419,10 @@ _ecore_con_cl_timer_update(Ecore_Con_Client *cl)
         if (cl->disconnect_time > 0)
           {
              if (cl->until_deletion)
-               ecore_timer_interval_set(cl->until_deletion, 
cl->disconnect_time);
+               {
+                  ecore_timer_interval_set(cl->until_deletion, 
cl->disconnect_time);
+                  ecore_timer_reset(cl->until_deletion);
+               }
              else
                cl->until_deletion = ecore_timer_add(cl->disconnect_time, 
(Ecore_Task_Cb)_ecore_con_client_timer, cl);
           }

-- 

------------------------------------------------------------------------------
Try New Relic Now & We'll Send You this Cool Shirt
New Relic is the only SaaS-based application performance monitoring service 
that delivers powerful full stack analytics. Optimize and monitor your
browser, app, & servers with just a few lines of code. Try New Relic
and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may

Reply via email to