1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-16 00:00:07 +01:00
libwebsockets/plugins
Andy Green caaf26c717 libuv: foreign loop detach doesn not require lws running the loop at all
This completely removes the loop self-running stuff.

Static allocations (uv_idle, timers etc) are referenced-counted in the context
same as the wsi are.  When lws wants to close, he first closes all his wsi, then
when that is completed in the uv close callbacks, he closes all of his static
uv handles.  When that is also completed in the uv callbacks, he stops the loop
so the lws context can destroy and exit.

Any direct libuv allocations in protocol handlers must participate in the
reference counting.  Two new apis are provided

 - lws_libuv_static_refcount_add(handle, context) to mark the handle with
   a pointer to the context and increment the global uv object counter

 - lws_libuv_static_refcount_del() which should be used as the close callback
   for your own libuv objects declared in the protocol scope.
2018-04-06 10:38:03 +08:00
..
acme-client lws_snprintf 2018-03-12 09:28:42 +08:00
generic-sessions lws_snprintf 2018-03-12 09:28:42 +08:00
generic-table lws_snprintf 2018-03-12 09:28:42 +08:00
ssh-base lws_snprintf 2018-03-12 09:28:42 +08:00
lwsws-logo.png http cache policy 2016-04-22 08:53:49 +08:00
protocol_client_loopback_test.c lws_snprintf 2018-03-12 09:28:42 +08:00
protocol_dumb_increment.c libuv: foreign loop detach doesn not require lws running the loop at all 2018-04-06 10:38:03 +08:00
protocol_esp32_lws_group.c plugins: group 2017-05-16 20:21:47 +08:00
protocol_esp32_lws_ota.c lws_snprintf 2018-03-12 09:28:42 +08:00
protocol_esp32_lws_reboot_to_factory.c esp32: separate factory setup 2017-03-31 20:05:10 +08:00
protocol_esp32_lws_scan.c lws_snprintf 2018-03-12 09:28:42 +08:00
protocol_lws_meta.c appveyor: Enable 64-bit build with OpenSSL and HTTP2 2017-11-26 19:16:17 +08:00
protocol_lws_mirror.c coverity 188310: mirror plugin: when reach max mirror instances release lock before disconnect 2018-04-06 10:38:03 +08:00
protocol_lws_raw_test.c minimal: minimal-raw-file 2018-04-06 10:38:03 +08:00
protocol_lws_server_status.c http2: make usable 2017-10-16 17:13:49 +08:00
protocol_lws_sshd_demo.c win32: remove snprintf mangling 2018-03-09 08:49:59 +08:00
protocol_lws_status.c lws_write_ws_flags helper 2018-04-06 10:38:03 +08:00
protocol_post_demo.c lws_snprintf 2018-03-12 09:28:42 +08:00
server-status.html http2: make usable 2017-10-16 17:13:49 +08:00