1
0
mirror of https://github.com/falk-werner/webfuse-provider synced 2026-03-02 04:09:18 +00:00

added function to interrupt _service calls

This commit is contained in:
Falk Werner
2020-03-07 15:27:04 +01:00
parent 627986e8b5
commit d2f078298e
8 changed files with 80 additions and 16 deletions

View File

@@ -111,8 +111,14 @@ bool wf_impl_server_is_operational(
}
void wf_impl_server_service(
struct wf_server * server,
int timeout_ms)
struct wf_server * server)
{
lws_service(server->context, timeout_ms);
lws_service(server->context, 0);
}
void wf_impl_server_interrupt(
struct wf_server * server)
{
lws_cancel_service(server->context);
}

View File

@@ -23,8 +23,10 @@ extern bool wf_impl_server_is_operational(
struct wf_server * server);
extern void wf_impl_server_service(
struct wf_server * server,
int timeout_ms);
struct wf_server * server);
extern void wf_impl_server_interrupt(
struct wf_server * server);
#ifdef __cplusplus
}