blob: db6fa2e5aa35eb47621e9bd1fa033c918a988bf8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
#ifndef __VXGG_REWRITE___THREADPOOL_H___13601325413136___
#define __VXGG_REWRITE___THREADPOOL_H___13601325413136___
#include <threads.h>
typedef int (*task_callback)(void*);
typedef struct task task;
typedef struct cq cqueue;
typedef struct tp threadpool;
task * task_init(task_callback cb, void *arg);
void task_free(task *ts);
int task_fire(task *ts);
cqueue * cqueue_init();
void cqueue_cancel(cqueue * const cq);
void cqueue_free(void *cq);
#endif
|