summaryrefslogtreecommitdiff
path: root/ot_fullscrape.c
diff options
context:
space:
mode:
Diffstat (limited to 'ot_fullscrape.c')
-rw-r--r--ot_fullscrape.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/ot_fullscrape.c b/ot_fullscrape.c
index 6f898c4..bcf238c 100644
--- a/ot_fullscrape.c
+++ b/ot_fullscrape.c
@@ -52,11 +52,15 @@ static void * fullscrape_worker( void * args) {
52 return NULL; 52 return NULL;
53} 53}
54 54
55static pthread_t thread_id;
55void fullscrape_init( ) { 56void fullscrape_init( ) {
56 pthread_t thread_id;
57 pthread_create( &thread_id, NULL, fullscrape_worker, NULL ); 57 pthread_create( &thread_id, NULL, fullscrape_worker, NULL );
58} 58}
59 59
60void fullscrape_deinit( ) {
61 pthread_cancel( thread_id );
62}
63
60void fullscrape_deliver( int64 socket, ot_tasktype tasktype ) { 64void fullscrape_deliver( int64 socket, ot_tasktype tasktype ) {
61 mutex_workqueue_pushtask( socket, tasktype ); 65 mutex_workqueue_pushtask( socket, tasktype );
62} 66}