Skip to main content

taskwd_insert

Function taskwd_insert 

Source
pub fn taskwd_insert(
    name: impl Into<String>,
    check_in: CheckIn,
    callback: Option<TaskwdCallback>,
) -> TaskwdEntry
Expand description

Watch this task — C taskwdInsert (taskwd.c:177-205).

name is what the console line and taskwd_show call it; give it the name the thread or task already has, so an operator can match the two. callback is what the task wants done when it is found stuck (C’s TASKWDFUNC); most call sites have none.

The task is watched until the returned handle is dropped.