forked from mirrors/kore
Make accesslogs optional
This commit is contained in:
parent
3f853a79ce
commit
cb3322cd9f
|
@ -228,6 +228,7 @@ struct kore_module_handle {
|
|||
int type;
|
||||
int errors;
|
||||
regex_t rctx;
|
||||
struct kore_domain *dom;
|
||||
struct kore_auth *auth;
|
||||
|
||||
TAILQ_HEAD(, kore_handler_params) params;
|
||||
|
|
|
@ -273,7 +273,9 @@ http_process_request(struct http_request *req, int retry_only)
|
|||
return;
|
||||
}
|
||||
|
||||
kore_accesslog(req);
|
||||
if (hdlr != NULL && hdlr->dom->accesslog != -1)
|
||||
kore_accesslog(req);
|
||||
|
||||
req->flags |= HTTP_REQUEST_DELETE;
|
||||
}
|
||||
|
||||
|
|
|
@ -179,6 +179,7 @@ kore_module_handler_new(char *path, char *domain, char *func,
|
|||
|
||||
hdlr = kore_malloc(sizeof(*hdlr));
|
||||
hdlr->auth = ap;
|
||||
hdlr->dom = dom;
|
||||
hdlr->errors = 0;
|
||||
hdlr->addr = addr;
|
||||
hdlr->type = type;
|
||||
|
|
Loading…
Reference in New Issue