libmicrohttpd
[Top][All Lists]
Advanced

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

[libmicrohttpd] Check for client disconnection on suspended connection


From: Robert D Kocisko
Subject: [libmicrohttpd] Check for client disconnection on suspended connection
Date: Mon, 29 Jul 2019 11:08:18 -0400

Hello all,

Context: Single thread, external select with epoll.

I have been using the suspend/resume flow control mechanism of libmicrohttpd to implement longpoll functionality, but now have a new use case where it is important to be able to check a particular connection while it is suspended to know whether the client has disconnected.  The only way I can imagine doing this is to resume the connection for some amount of time (how long?) and see whether the MHD_OPTION_NOTIFY_COMPLETED callback gets called and then suspend the connection again.  But I'm wondering if there's a simpler way to do this that doesn't involve resuming and waiting for a callback?

Thanks,
Bob

reply via email to

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