summaryrefslogtreecommitdiffstats
path: root/worker.c
blob: c6698d9c50c610be508c3e91d4a1e1eb8e527dd3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include "./lib/worker.h"

void func(const char* task, size_t task_size, char** resp, size_t* resp_size) {
    printf("HERE %*s\n", (int) task_size, task);

    task = task;
    task_size = task_size;
    *resp = malloc(10);
    *resp_size = 10;
    sleep(1);
}

int32_t main() {
    worker_init("127.0.0.1", "33554", 2, func);
    worker_exec();
}