summaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c19
1 files changed, 17 insertions, 2 deletions
diff --git a/src/main.c b/src/main.c
index 2fcf8ab..f89a124 100644
--- a/src/main.c
+++ b/src/main.c
@@ -3,12 +3,27 @@
3#include "encryption.h" 3#include "encryption.h"
4#include "scanner.h" 4#include "scanner.h"
5#include "shared.h" 5#include "shared.h"
6 6#include "threadpool.h"
7 7
8#include <errno.h> 8#include <errno.h>
9#include <error.h> 9#include <error.h>
10 10
11#include <stdio.h>
12int testcb(void *data) {
13 if(!data)
14 return -1;
15
16 printf("%s\n", (char*)data);
17 return 0;
18}
19
11int main() { 20int main() {
12 error(1, ENOTSUP, "No main file lol"); 21 // error(1, ENOTSUP, "No main file lol");
22
23 threadpool *tp = threadpool_init(2);
24 task *tsk = task_init(testcb, "This is some data");
25 threadpool_addtask(tp, tsk);
26 threadpool_free(tp);
27
13 return 0; 28 return 0;
14} \ No newline at end of file 29} \ No newline at end of file