Commit 61ef227c authored by Jan Včelák's avatar Jan Včelák 🚀
Browse files

Merge branch 'invalid-close' into 'master'

Closes #332
parents 4da29260 3c22b0dd
......@@ -148,7 +148,9 @@ struct knot_request *knot_request_make(mm_ctx_t *mm,
_public_
int knot_request_free(mm_ctx_t *mm, struct knot_request *request)
{
close(request->fd);
if (request->fd >= 0) {
close(request->fd);
}
knot_pkt_free(&request->query);
knot_pkt_free(&request->resp);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment