lwip-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-devel] [bug #19222] timeout in sys_mbox_fetch


From: Dmitry Potapov
Subject: [lwip-devel] [bug #19222] timeout in sys_mbox_fetch
Date: Wed, 07 Mar 2007 10:08:11 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.10) Gecko/20070216 Firefox/1.5.0.10

Follow-up Comment #12, bug #19222 (project lwip):

Frédéric,

Besides, the expression to find minimum as we discussed yesterday:

 (timeout!=0) ? min( timeout, timeouts->next->time) : timeouts->next->time)

you also need to add the following 5 lines
(I marked them with '+' at the beginning):

      /* If time != SYS_ARCH_TIMEOUT, a message was received before the
timeout
   occured. The time variable is set to the number of
   milliseconds we waited for the message. */
      if (time <= timeouts->next->time) {
  timeouts->next->time -= time;
      } else {
  timeouts->next->time = 0;
      }
+     if(timeout) {
+        timeout -= time;
+        if(timeout == 0)
+           break;
+     }
    }


    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/bugs/?19222>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.nongnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]