Do you use HTTP or HTTPS?
Eventually, since it's a framework for both http and https, I will use
both protocols.
You must not call MHD_stop_daemon() while you still have some not closed
"upgraded" connections.
May be we should add more alarming message in case of such API violation.
I understand.
What I have thought of is to store a signature of all opened upgraded
connections in an array, then before calling MHD_stop_daemon(), going
through each connection, and close them. I guess that's the most clean
way to do it.
Could you provide a minimal example?
The file
https://github.com/babelouest/ulfius/blob/2.0/example_programs/websocket_example/websocket_example.c
provides a minimal example of what I intend to do, although it's still
in progress.