On Sat, 25 Sep 2021 17:35:42 +0300 Evgeny Grin <k...@yandex.ru> wrote:
> Hi José, > > Thanks for the report! > > If MHD needs to (re-)run MHD_run() immediately MHD_get_timeout() must > return zero timeout. > You don't need to re-run it if no timeout is returned. > Zero timeout if connection cleanup is pending was enforced by > Christian in version 0.9.73. > See > https://lists.gnu.org/archive/html/libmicrohttpd/2021-01/msg00003.html > Let me know if it doesn't work for you, so we will be able to fix it > before the next release. Hi Evgeny, that is a good new that I either missed or forgot. I have no big ideaon how to check that change. So I'll trust Christian's made a good job as usual. > Function MHD_run_wait() was added for upcoming version 0.9.74, but it > does not return flag "need to re-run". MHD_get_timeout() already > serves for this purpose. I finally had time to look at this new function. It can be improved by returning a status telling if something was processed or not instead of just ok/error. This would allow to call it with a timeout of 0 until nothing is done. Best regards José