Author: rco
Date: 2008-06-02 10:58:17 +0200 (Mon, 02 Jun 2008)
New Revision: 1000

Modified:
   trunk/core/plug-in/sipctrl/sip_trans.cpp
   trunk/core/plug-in/sipctrl/wheeltimer.cpp
   trunk/core/plug-in/sipctrl/wheeltimer.h
Log:
- hopefully fixes some small bugs in the wheel-timer.


Modified: trunk/core/plug-in/sipctrl/sip_trans.cpp
===================================================================
--- trunk/core/plug-in/sipctrl/sip_trans.cpp    2008-06-01 08:03:27 UTC (rev 
999)
+++ trunk/core/plug-in/sipctrl/sip_trans.cpp    2008-06-02 08:58:17 UTC (rev 
1000)
@@ -117,7 +117,8 @@
     if(bucket){
        bucket->lock();
        if(bucket->exist(tr)){
-           DBG("Transaction timer expired: type=0x%x, trans=%p\n",t->type,tr);
+           DBG("Transaction timer expired: type=0x%x, trans=%p, eta=%i, 
t=%i\n",
+               t->type,tr,t->expires,wheeltimer::instance()->wall_clock);
            trans_layer::instance()->timer_expired(t,bucket,tr);
        }
        else {

Modified: trunk/core/plug-in/sipctrl/wheeltimer.cpp
===================================================================
--- trunk/core/plug-in/sipctrl/wheeltimer.cpp   2008-06-01 08:03:27 UTC (rev 
999)
+++ trunk/core/plug-in/sipctrl/wheeltimer.cpp   2008-06-02 08:58:17 UTC (rev 
1000)
@@ -101,7 +101,7 @@
       sdiff.tv_sec = diff.tv_sec;
       sdiff.tv_nsec = diff.tv_usec * 1000;
 
-      if(sdiff.tv_nsec > 2000) // 2 ms 
+      if(sdiff.tv_nsec > 2000000) // 2 ms 
        nanosleep(&sdiff,&rem);
     }
     //else {

Modified: trunk/core/plug-in/sipctrl/wheeltimer.h
===================================================================
--- trunk/core/plug-in/sipctrl/wheeltimer.h     2008-06-01 08:03:27 UTC (rev 
999)
+++ trunk/core/plug-in/sipctrl/wheeltimer.h     2008-06-02 08:58:17 UTC (rev 
1000)
@@ -123,7 +123,7 @@
     static wheeltimer* instance();
 
     //clock reference
-    u_int32_t wall_clock; // 32 bits
+    volatile u_int32_t wall_clock; // 32 bits
 
     void clock_work();
     void insert_timer(timer* t);

_______________________________________________
Semsdev mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/semsdev

Reply via email to