[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[Libevent-users] evhttp_accept_socket_with_handle() implies LEV_CLOSE_ON_FREE on underlying evconnlistener
- To: libevent-users@xxxxxxxxxxxxx
- Subject: [Libevent-users] evhttp_accept_socket_with_handle() implies LEV_CLOSE_ON_FREE on underlying evconnlistener
- From: Constantine Verutin <cverutin@xxxxxxxxx>
- Date: Thu, 10 Feb 2011 23:27:47 +0200
- Delivered-to: archiver@xxxxxxxx
- Delivered-to: libevent-users-outgoing@xxxxxxxx
- Delivered-to: libevent-users@xxxxxxxx
- Delivery-date: Thu, 10 Feb 2011 16:27:55 -0500
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=oIjhGggfuIHGr709tx4YcjfSpaJf2El+MckYBVVaZf4=; b=m+p8ITeMPxHch7IpcEVmn9A8kEvw2uS8mn3yh594fvz5ioI9SK1p45EE7fvmt6+pEf Sz7JdDOlBwTi+U4LqUWflx0j4r0dCwJ8M9Bz4T1f9Tjxg51IcrOcTtcmA54U2EJpr0BF /eL4p2xACQmfeJYNwmeTpKfVH0G6mH6sIW7nU=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=hN1PPngAHT0saYKH7y8d3PvVdQrgVWrnpkqXoJd0MWP+6xI0seamoBWEenfVCUmHgJ 5XOHbzkl8+6CQU2naP9G/+/r6wp1NKWV0kdI8cMWHnTf0P6yUskQ/lBxqYcUUM/m2cGs 7Td7efvJjYSF2kY7EHDI6L8+xVWJ0IqSQWsVc=
- Reply-to: libevent-users@xxxxxxxxxxxxx
- Sender: owner-libevent-users@xxxxxxxxxxxxx
Hi guys,
I noticed that evhttp_accept_socket_with_handle() sets the LEV_OPT_CLOSE_ON_FREE flag on underlying evconnlistener, and in this case calling evhttp_del_accept_socket() later causes socket fd to be freed(while documentation explicitly says this function does not close). Is this a bug? Or I should create evconnlistener manually and use evhttp_bind_listener?
--
WBR,
ÂConstantine