18 lines
388 B
C
18 lines
388 B
C
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
#include <string.h>
|
|
#include <stdint.h>
|
|
#include <errno.h>
|
|
#include <evhtp.h>
|
|
|
|
int
|
|
main(int argc, char ** argv) {
|
|
evbase_t * evbase = event_base_new();
|
|
evhtp_t * htp = evhtp_new(evbase, NULL);
|
|
|
|
evhtp_use_threads(htp, NULL, 4, NULL);
|
|
evhtp_bind_socket(htp, "0.0.0.0", 8080, 1024);
|
|
event_base_loop(evbase, 0);
|
|
return 0;
|
|
}
|
|
|