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

@@ -84,9 +84,13 @@ bool wfp_impl_client_is_connected(
}
void wfp_impl_client_service(
struct wfp_client * client,
int timeout_ms)
struct wfp_client * client)
{
lws_service(client->context, timeout_ms);
lws_service(client->context, 0);
}
void wfp_impl_client_interrupt(
struct wfp_client * client)
{
lws_cancel_service(client->context);
}

View File

@@ -38,8 +38,10 @@ extern bool wfp_impl_client_is_connected(
struct wfp_client * client);
extern void wfp_impl_client_service(
struct wfp_client * client,
int timeout_ms);
struct wfp_client * client);
extern void wfp_impl_client_interrupt(
struct wfp_client * client);
#ifdef __cplusplus
}