|
From: | Douglas |
Subject: | [lwip-devel] [patch #9533] sys_check_timeouts: recalculate the time diff after each handler call |
Date: | Thu, 4 Jan 2018 07:23:04 -0500 (EST) |
User-agent: | Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:57.0) Gecko/20100101 Firefox/57.0 |
URL: <http://savannah.nongnu.org/patch/?9533> Summary: sys_check_timeouts: recalculate the time diff after each handler call Project: lwIP - A Lightweight TCP/IP stack Submitted by: ourairquality Submitted on: Thu 04 Jan 2018 12:23:02 PM UTC Category: None Priority: 5 - Normal Status: None Privacy: Public Assigned to: None Originator Email: Open/Closed: Open Discussion Lock: Any Planned Release: None _______________________________________________________ Details: If there is only one timeout then when the handler is called there will be none. If the handler then calls sys_timeout to install another handler and then sys_timeout will reset the timeouts_last_time. When the handler returns to the sys_check_timeouts loop it was continuing to use a stale diff value and incorrectly checking the times. This patch modifies sys_check_timeouts to sample sys_now() and timeouts_last_time each time around the loop. This allowed some cleanup of the code. Also PBUF_CHECK_FREE_OOSEQ() is now called even if there are no timeouts. _______________________________________________________ File Attachments: ------------------------------------------------------- Date: Thu 04 Jan 2018 12:23:02 PM UTC Name: 0001-sys_check_timeouts-recalculate-the-time-diff-after-e.patch Size: 3KiB By: ourairquality <http://savannah.nongnu.org/patch/download.php?file_id=42822> _______________________________________________________ Reply to this item at: <http://savannah.nongnu.org/patch/?9533> _______________________________________________ Message sent via/by Savannah http://savannah.nongnu.org/
[Prev in Thread] | Current Thread | [Next in Thread] |