mirror of https://git.kore.io/kore.git
fix potential NULL dereferences.
found by clang --analyze, reminded by fahlgren@
This commit is contained in:
parent
ff2d961be7
commit
7cf0006f52
|
@ -1991,7 +1991,7 @@ http_response_normal(struct http_request *req, struct connection *c,
|
|||
kore_buf_append(header_buf, http_version, http_version_len);
|
||||
|
||||
if ((c->flags & CONN_CLOSE_EMPTY) ||
|
||||
(req->flags & HTTP_VERSION_1_0)) {
|
||||
(req != NULL && (req->flags & HTTP_VERSION_1_0))) {
|
||||
connection_close = 1;
|
||||
} else {
|
||||
connection_close = 0;
|
||||
|
|
|
@ -627,6 +627,8 @@ kore_worker_keymgr_response_verify(struct kore_msg *msg, const void *data,
|
|||
if (out == NULL)
|
||||
return (KORE_RESULT_OK);
|
||||
|
||||
dom = NULL;
|
||||
|
||||
LIST_FOREACH(srv, &kore_servers, list) {
|
||||
dom = NULL;
|
||||
|
||||
|
|
Loading…
Reference in New Issue