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

@@ -46,13 +46,29 @@ extern WF_API void wf_server_dispose(
/// This function must be invoked in a loop while the server is running. It
/// makes the server wait for the next event and processes it.
///
/// \note timeout_ms is no longer used
///
/// \param server pointer to server
/// \param timeout_ms timeout in milliseconds.
/// \param timeout_ms unused; set to 0; used for backward compatibility
///
/// \see wf_server_interrupt
//------------------------------------------------------------------------------
extern WF_API void wf_server_service(
struct wf_server * server,
int timeout_ms);
//------------------------------------------------------------------------------
/// \brief Interrupts wf_server_service
///
/// This function can be used from another thread.
///
/// \param server pointer to server
///
/// \see wf_server_service
//------------------------------------------------------------------------------
extern WF_API void wf_server_interrupt(
struct wf_server * server);
#ifdef __cplusplus
}
#endif

View File

@@ -78,13 +78,29 @@ extern WFP_API void wfp_client_dispose(
/// This function must be invoked in a loop while the client is running. It
/// makes the server wait for the next event and processes it.
///
/// \note timeout is ignored
///
/// \param client pointer to client
/// \param timeout_ms timeout in milliseconds.
/// \param timeout_ms unused; set to 0; for backward compatibilty
///
/// \see wfp_client_interrupt
//------------------------------------------------------------------------------
extern WFP_API void wfp_client_service(
struct wfp_client * client,
int timeout_ms);
//------------------------------------------------------------------------------
/// \brief interrupt wfp_client_service
///
/// This function can be called from another thread.
///
/// \param client pointer to client
///
/// \see wfp_client_service
//------------------------------------------------------------------------------
extern WFP_API void wfp_client_interrupt(
struct wfp_client * client);
#ifdef __cplusplus
}
#endif