Dear Sir/MadamWhen using libmicrohttpd-0.9.9 in our program on redhat 6u, we 
find the issue that requests  are refused randomly . Then we check the code, 
find that the micro-second part of a struct timeval tv is not initialized, so 
it could be randomly set negative.Following is our patch to fix the bug:--- 
daemon.c 2014-05-05 11:43:03.004311322 +0800
+++ daemon.c 2014-05-05 11:42:57.220306712 +0800
@@ -581,6 +581,7 @@
 tv.tv_sec = 0;
 else
 tv.tv_sec = timeout - (now - con->last_activity);
+ tv.tv_usec = 0;
 tvp = &tv;
 }
 if ((con->state == MHD_CONNECTION_NORMAL_BODY_UNREADY) ||
Thankserbai------------------------------------------------------------------
发件人:libmicrohttpd-confirm+0e5368a6295b356e00e045f54d0d62ce7b5e8397 
<libmicrohttpd-confirm+0e5368a6295b356e00e045f54d0d62ce7b5e8...@gnu.org>
发送时间:2014年5月5日(星期一) 11:39
收件人:钱在晨(二败) <[email protected]>
主 题:Your confirmation is required to join the libmicrohttpd mailing list

Mailing list subscription confirmation notice for mailing list
libmicrohttpd

We have received a request from 115.236.14.174 for subscription of
your email address, "[email protected]", to the
[email protected] mailing list.  To confirm that you want to be
added to this mailing list, simply reply to this message, keeping the
Subject: header intact.  Or visit this web page:

    
https://lists.gnu.org/mailman/confirm/libmicrohttpd/0e5368a6295b356e00e045f54d0d62ce7b5e8397


Or include the following line -- and only the following line -- in a
message to [email protected]:

    confirm 0e5368a6295b356e00e045f54d0d62ce7b5e8397

Note that simply sending a `reply' to this message should work from
most mail readers, since that usually leaves the Subject: line in the
right form (additional "Re:" text in the Subject: is okay).

If you do not wish to be subscribed to this list, please simply
disregard this message.  If you think you are being maliciously
subscribed to the list, or have any other questions, send them to
[email protected].

Reply via email to