forked from mirrors/kore
req can be NULL if we are coming from an error path.
This commit is contained in:
parent
e95d9cc88e
commit
a20fb00789
|
@ -1247,7 +1247,8 @@ http_response_normal(struct http_request *req, struct connection *c,
|
|||
}
|
||||
}
|
||||
|
||||
if (req->owner->proto != CONN_PROTO_WEBSOCKET) {
|
||||
/* Note that req CAN be NULL. */
|
||||
if (req != NULL && req->owner->proto != CONN_PROTO_WEBSOCKET) {
|
||||
if (http_keepalive_time && connection_close == 0) {
|
||||
kore_buf_appendf(header_buf,
|
||||
"connection: keep-alive\r\n");
|
||||
|
|
Loading…
Reference in New Issue