Skip to main content

module_process

Function module_process 

Source
pub extern "C" fn module_process(
    fd: BorrowedFd<'_>,
    block: c_int,
) -> c_int
Expand description

Process the module input, interpreting the SSIP protocol and calling appropriate module-provided functions

This can be either

  • be called with block set to 1, to only return when the server sends QUIT (acting as the main loop for the module)
  • or called with block set to 0, to only process what was already sent by the server and not wait for any further requests.

Typically this would be called periodically by the module, to let the server inform the module when it should stop.